| [news.eclipse.tools.emf] Re: Custom code after initialization (Short question) [to: Zac] |
I had a similar requirement and I ended up overriding the doDefaultElementCreation() method in the CreateCommand class for my element and creating the child objects there on the actual EObject. Something like this:
/** * @generated NOT */ @Override protected EObject doDefaultElementCreation() { MyObject obj = (MyObject) super.doDefaultElementCreation(); obj.createChildObjects(); return obj; }
Hi!
Regards,
Tomas Zijdemans