Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » Papyrus » Problem setting the Creation Command Class in my architecture model
Problem setting the Creation Command Class in my architecture model [message #1772890] Mon, 18 September 2017 12:53 Go to next message
Patrik Nandorf is currently offline Patrik NandorfFriend
Messages: 165
Registered: January 2013
Location: Sweden
Senior Member
Hi,

When trying to set the qualified name of my creation command class in the properties view when editing my architecture model I get the following error:

"WrappedException: java.lang.ClassNotFound Exception: <whatever I type> cannot be found by org.eclipse.emf.ecore_2.13.v20170609-0707

Also see attached screen shot

The class I'm entering does exist and implements IModelCreationCommand.

What am I missing?

Regards
Patrik



Re: Problem setting the Creation Command Class in my architecture model [message #1772897 is a reply to message #1772890] Mon, 18 September 2017 13:32 Go to previous messageGo to next message
Camille Letavernier is currently offline Camille LetavernierFriend
Messages: 878
Registered: February 2011
Senior Member
Hi Patrik,

The EMF Model will look for the class into the current Class loader. However, at development time, the Class loader doesn't contain your class, yet.

So you have two options:

- Ignore the error, it will disappear at runtime (But it may be painful to actually edit the model, as the error will repeatedly occur)
- Edit your model in a runtime instance (Or install the plug-in containing the class in your development instance)

HTH,
Camille


Camille Letavernier
Re: Problem setting the Creation Command Class in my architecture model [message #1772898 is a reply to message #1772897] Mon, 18 September 2017 13:47 Go to previous messageGo to next message
Patrik Nandorf is currently offline Patrik NandorfFriend
Messages: 165
Registered: January 2013
Location: Sweden
Senior Member
Again, thanks for a quick reply
Re: Problem setting the Creation Command Class in my architecture model [message #1772986 is a reply to message #1772897] Tue, 19 September 2017 18:01 Go to previous messageGo to next message
Patrik Nandorf is currently offline Patrik NandorfFriend
Messages: 165
Registered: January 2013
Location: Sweden
Senior Member
I did try option #2 and it works even though it is cumbersome.

However #1 doesn't work as the property field doesn't accept anything if the class isn't found.

Any particular reason why you do the validation while entering the name? Personally I would prefer that kind of check when validating the model. Or at least when leaving the field or pressing enter, not for every keystroke it seem to be now.


Camille Letavernier wrote on Mon, 18 September 2017 15:32
Hi Patrik,

So you have two options:

- Ignore the error, it will disappear at runtime (But it may be painful to actually edit the model, as the error will repeatedly occur)
- Edit your model in a runtime instance (Or install the plug-in containing the class in your development instance)

HTH,
Camille

Re: Problem setting the Creation Command Class in my architecture model [message #1773001 is a reply to message #1772986] Wed, 20 September 2017 07:03 Go to previous message
Camille Letavernier is currently offline Camille LetavernierFriend
Messages: 878
Registered: February 2011
Senior Member
Hi Patrik,

I also think it shouldn't happen. The reason is that the command property is typed with a Class DataType, so EMF automatically validates that the class exists. A String property will custom validation would certainly be easier to work with.

Cheers,
Camille


Camille Letavernier
Previous Topic:Documentation for the new Palette configuration model format
Next Topic:Papyrus files extension
Goto Forum:
  


Current Time: Mon Jun 25 14:14:23 GMT 2018

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

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

Back to the top