|
Re: Name attribute [message #1760399 is a reply to message #1760342] |
Wed, 26 April 2017 16:18 |
Ed Merks Messages: 33217 Registered: July 2009 |
Senior Member |
|
|
It's a GMF question. Looking at that code it really only works if there is a feature called "name" in the EClass so to make that work, only changing the Ecore model would work. Failing that, you have to specialize the code that calls this getName method. Perhaps you could define a name attribute, make it transient, volatile, derived, and non-changeable, mark it as have suppressed visibility (i.e., add an annotation exactly like what org.eclipse.emf.ecore.util.EcoreUtil.setSuppressedVisibility(EStructuralFeature, int, boolean) does) so that it's not visible in the generated interface, and then implement the getName method in the Impl class to return your other string attribute's value.
Ed Merks
Professional Support: https://www.macromodeling.com/
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.04328 seconds