Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Archived » Visual Editor (VE) » Incorrect class name created in EMF
Incorrect class name created in EMF [message #128335] Tue, 11 July 2006 14:06 Go to next message
Eclipse UserFriend
Originally posted by: xubin.wei.ellingtonpcb.com

hi,
I have new plugin install in VE environment, but it seem can't create the
correct class in EMF ? why ? -
[1] I have add the class name in
cymodel.xmi
<?xml version="1.0" encoding="UTF-8"?>
<children ... creationClassURI="java:/com.cy.ve.widget#Simplemodel">
<entryLabel
xsi:type="org.eclipse.ve.internal.cde.utility:ConstantString "
string="Simplemodel"/>
<keyedValues xsi:type="ecore:EStringToStringMapEntry"
key="org.eclipse.ve.internal.cde.core.nameincomposition"
value="sSimplemodel"/>
</children>
</org.eclipse.ve.internal.cde.palette:Drawer>

[2] But in EMF decode the JAVA source,
we find it does not create the correct class name, there are use parent
class name
'Shell' replaced.


private Simplemodel sSimplemodel = null; //
@jve:decl-index=0:visual-constraint="198,90"

/**
* This method initializes sSimplemodel
*
*/
private void createSSimplemodel() {
// it should be sSimplemodel = new
// Simplemodel();
sSimplemodel = new Shell();

sSimplemodel.setLayout(new GridLayout());
}
Re: Incorrect class name created in EMF [message #128349 is a reply to message #128335] Tue, 11 July 2006 14:46 Go to previous message
Eclipse UserFriend
Originally posted by: richkulp.us.NO_SPAM.ibm.com

SimpleModel shouldn't inherit from Shell because shell is effectively
final. It is not supposed to be subclassed.

I don't know why it says new Shell though. That would only happen if
SimpleModel has not been compiled, that only the source is available.

--
Thanks,
Rich Kulp
Re: Incorrect class name created in EMF [message #613509 is a reply to message #128335] Tue, 11 July 2006 14:46 Go to previous message
Eclipse UserFriend
Originally posted by: richkulp.us.NO_SPAM.ibm.com

SimpleModel shouldn't inherit from Shell because shell is effectively
final. It is not supposed to be subclassed.

I don't know why it says new Shell though. That would only happen if
SimpleModel has not been compiled, that only the source is available.

--
Thanks,
Rich Kulp
Previous Topic:Incorrect class name created in EMF
Next Topic:Remove allocation code if cancel
Goto Forum:
  


Current Time: Wed Apr 24 21:57:32 GMT 2024

Powered by FUDForum. Page generated in 0.03298 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top