Edit->Validate and EVL in EOL [message #759479] |
Mon, 28 November 2011 14:25  |
Eclipse User |
|
|
|
Hi everybody.
I've wrote some constraint in .evl file and in a gmf editor(result of a new eclipse instance) by clicking Edit->Validate those constraints defined in the .evl file are checked normally. As far as good.
Now, I want to do a second step but it could be made just if the Edit->Validate was performed.
Is there a way to check this ?
Thank you in advance for the support.
|
|
|
|
|
|
Re: Edit->Validate and EVL in EOL [message #820144 is a reply to message #782948] |
Tue, 13 March 2012 15:42   |
Eclipse User |
|
|
|
Hi, Horacio Hoyos
first, I thank you for your support! It is of great help.
That pseudocode depicts almost perfectly my idea. But I'm not calling any java code. I'm just using just epsilon and a single .evl file (and wizards through EWL too).
I've had this idea:
In each evl constraint , in the 'check' I've added a dumb function like
context AnyClass
{
constraint anyConstraint
{
check: dumb(self.name<>'')//self.name<>'' is the real constraint I want to check
message: 'Any message'
}
}
operation dumb(x:Boolean, a:AnyClass)
{
//storage the value of x in any variable
a.error:=x; //It raises an error!!!!
return x;
}
So, every time any constraint was checked the dumb function would be called allowing to store the value of the verification.
But, at the line ''a.error:=x;'' an error is raised.
In few words, this is the error:
an runtime erro was raised during the evaluation ... Internal Error: java.lang.IllegalStateException: Cannot modify resource set without a write transaction
Apparently, I need to declare a write transaction but I have absolutely no idea of where to start.
Anyway, I thank you again for your time and attention!
Best regards
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.04719 seconds