Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » Epsilon » adding markers to eugenia based editor after applying evl constraints to emfdiff model
adding markers to eugenia based editor after applying evl constraints to emfdiff model [message #527798] Fri, 16 April 2010 14:24 Go to next message
saad bin abid is currently offline saad bin abidFriend
Messages: 60
Registered: October 2009
Location: Ireland
Member
Hello Community,
I am currently working with consistency checking. I am comparing two model of same meta model and getting errors markers in the validation view of the EVL after applying the EVL constraints on the emfdiff model generated after model comparison. I want to attach the evl constraints which i am applying to emf diffmodel with eugenia based editor.
I have the following questions

which exentions should be used to attach the evl constraints for emfdiff model so that i get the errors in the errors view ?
and how can i see the error markers in the eugenia based editor?

is there any other efficient way of solving the above mentioned challenge?

best regards
saad
Re: adding markers to eugenia based editor after applying evl constraints to emfdiff model [message #527828 is a reply to message #527798] Fri, 16 April 2010 14:58 Go to previous messageGo to next message
Dimitrios Kolovos is currently offline Dimitrios KolovosFriend
Messages: 1776
Registered: July 2009
Senior Member
Hi Saad,

There's no built-in support for this. I guess what you'll have to do is
to find the markers in the diffmodel, resolve the target eObject that
marked diffs refer to, look in the workspace for diagrams that point at
these eObjects and add markers to the respective diagram elements.

Cheers,
Dimitris

saad bin abid wrote:
> Hello Community,
> I am currently working with consistency checking. I am comparing two
> model of same meta model and getting errors markers in the validation
> view of the EVL after applying the EVL constraints on the emfdiff model
> generated after model comparison. I want to attach the evl constraints
> which i am applying to emf diffmodel with eugenia based editor. I have
> the following questions
>
> which exentions should be used to attach the evl constraints for emfdiff
> model so that i get the errors in the errors view ?
> and how can i see the error markers in the eugenia based editor?
>
> is there any other efficient way of solving the above mentioned challenge?
>
> best regards
> saad


--
Spread the word: http://www.eclipse.org/gmt/epsilon/spreadtheword
Follow Epsilon on Twitter: http://twitter.com/epsilonews
Re: adding markers to eugenia based editor after applying evl constraints to emfdiff model [message #527961 is a reply to message #527828] Sat, 17 April 2010 14:04 Go to previous messageGo to next message
saad bin abid is currently offline saad bin abidFriend
Messages: 60
Registered: October 2009
Location: Ireland
Member
Hello Dimitrios,
Thanks for the reply. As a starting point I am trying to work out with "EvlStandaloneExample". I checked out from epsilon svn. I am running the "EvlStandaloneExample.java", but i am getting the following error

java.lang.UnsupportedClassVersionError: Bad version number in .class file
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(Unknown Source)
at java.security.SecureClassLoader.defineClass(Unknown Source)
at java.net.URLClassLoader.defineClass(Unknown Source)
at java.net.URLClassLoader.access$100(Unknown Source)
at java.net.URLClassLoader$1.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClassInternal(Unknown Source)
Exception in thread "main"


Am i missing something? or if there is some pre setup i need to consider?

best regards
saad
Re: adding markers to eugenia based editor after applying evl constraints to emfdiff model [message #527964 is a reply to message #527961] Sat, 17 April 2010 14:33 Go to previous messageGo to next message
Dimitrios Kolovos is currently offline Dimitrios KolovosFriend
Messages: 1776
Registered: July 2009
Senior Member
Hi Saad,

This sounds like a Java version problem. Which JRE version are you
using?

Cheers,
Dimitris

saad bin abid <saad.softwareengineer@gmail.com> wrote:
> Hello Dimitrios,
> Thanks for the reply. As a starting point I am trying to work out with
> "EvlStandaloneExample". I checked out from epsilon svn. I am running
> the "EvlStandaloneExample.java", but i am getting the following error
>
> java.lang.UnsupportedClassVersionError: Bad version number in .class
> file
> at java.lang.ClassLoader.defineClass1(Native Method)
> at java.lang.ClassLoader.defineClass(Unknown Source)
> at java.security.SecureClassLoader.defineClass(Unknown Source)
> at java.net.URLClassLoader.defineClass(Unknown Source)
> at java.net.URLClassLoader.access$100(Unknown Source)
> at java.net.URLClassLoader$1.run(Unknown Source)
> at java.security.AccessController.doPrivileged(Native Method)
> at java.net.URLClassLoader.findClass(Unknown Source)
> at java.lang.ClassLoader.loadClass(Unknown Source)
> at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
> at java.lang.ClassLoader.loadClass(Unknown Source)
> at java.lang.ClassLoader.loadClassInternal(Unknown Source)
> Exception in thread "main"
>
> Am i missing something? or if there is some pre setup i need to
> consider?
>
> best regards
> saad
>
Re: adding markers to eugenia based editor after applying evl constraints to emfdiff model [message #527995 is a reply to message #527964] Sun, 18 April 2010 12:56 Go to previous messageGo to next message
saad bin abid is currently offline saad bin abidFriend
Messages: 60
Registered: October 2009
Location: Ireland
Member
Hello Dimitrios,
thanks again for the reply. yes i changed the Jre version and it started working now. I have one more question regarding

models.add(createEmfModel("Model", "models/result.emfdiff", "x", true, true));

when i am trying to load the models both the instance and the meta model, I want to know what should i put in "x", which has to be the meta model for the emfdiff model? any ideas how can i actually load the models before i apply the constraints on results.emfdiff?

best regards
saad
Re: adding markers to eugenia based editor after applying evl constraints to emfdiff model [message #528123 is a reply to message #527995] Mon, 19 April 2010 12:29 Go to previous messageGo to next message
Dimitrios Kolovos is currently offline Dimitrios KolovosFriend
Messages: 1776
Registered: July 2009
Senior Member
Hi Saad,

The namespace uri of *.emfdiff models is
http://www.eclipse.org/emf/compare/diff/1.1 As you're running this
through a standalone Java application, please make sure that the EMF
diff EPackage is actually in the EPackage registry before trying to load
the model.

Cheers,
Dimitris

saad bin abid wrote:
> Hello Dimitrios,
> thanks again for the reply. yes i changed the Jre version and it started
> working now. I have one more question regarding
>
> models.add(createEmfModel("Model", "models/result.emfdiff", "x", true,
> true));
>
> when i am trying to load the models both the instance and the meta
> model, I want to know what should i put in "x", which has to be the meta
> model for the emfdiff model? any ideas how can i actually load the
> models before i apply the constraints on results.emfdiff?
>
> best regards
> saad


--
Spread the word: http://www.eclipse.org/gmt/epsilon/spreadtheword
Follow Epsilon on Twitter: http://twitter.com/epsilonews
Re: adding markers to eugenia based editor after applying evl constraints to emfdiff model [message #528673 is a reply to message #528123] Wed, 21 April 2010 12:59 Go to previous messageGo to next message
saad bin abid is currently offline saad bin abidFriend
Messages: 60
Registered: October 2009
Location: Ireland
Member
Hello Dimitrios,

Thank you again. I used the following code in EvlStandaloneExample.java class to upload the models

@Override
public List<IModel> getModels() throws Exception {
List<IModel> models = new ArrayList<IModel>();

String file=" C:/eclipse-Galileo/eclipse/Sciaml-Test/ie.lero.helloworld.de mo.compare/diffmodel/result.emfdiff ";
models.add(createEmfModelByURI("Model", file, "http://www.eclipse.org/emf/compare/diff/1.1", true, true));
return models;
}

@Override
public String getSource() throws Exception {
return " C:/eclipse-Galileo/eclipse/Sciaml-Test/ie.lero.helloworld.de mo.compare/diffmodel.evl ";
}


where "result.emfdiff" and "diffmodel.evl" are in runtime enviornment. When i run the code using incremental plug-in i get the following error


java.lang.NullPointerException
at org.eclipse.epsilon.examples.standalone.EpsilonStandaloneExa mple.getFile(EpsilonStandaloneExample.java:98)
at org.eclipse.epsilon.examples.standalone.EpsilonStandaloneExa mple.execute(EpsilonStandaloneExample.java:45)
at ie.lero.scicalc.emfdiffmarkers.builder.SampleBuilder.checkXM L(SampleBuilder.java:113)
at ie.lero.scicalc.emfdiffmarkers.builder.SampleBuilder$SampleR esourceVisitor.visit(SampleBuilder.java:62)
at org.eclipse.core.internal.resources.Resource$2.visit(Resourc e.java:108)
at org.eclipse.core.internal.resources.Resource$1.visitElement( Resource.java:60)
at org.eclipse.core.internal.watson.ElementTreeIterator.doItera tion(ElementTreeIterator.java:82)
at org.eclipse.core.internal.watson.ElementTreeIterator.doItera tion(ElementTreeIterator.java:86)
at org.eclipse.core.internal.watson.ElementTreeIterator.iterate (ElementTreeIterator.java:127)
at org.eclipse.core.internal.resources.Resource.accept(Resource .java:70)
at org.eclipse.core.internal.resources.Resource.accept(Resource .java:106)
at org.eclipse.core.internal.resources.Resource.accept(Resource .java:90)
at ie.lero.scicalc.emfdiffmarkers.builder.SampleBuilder.fullBui ld(SampleBuilder.java:124)
at ie.lero.scicalc.emfdiffmarkers.builder.SampleBuilder.build(S ampleBuilder.java:93)
at org.eclipse.core.internal.events.BuildManager$2.run(BuildMan ager.java:627)
at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42)
at org.eclipse.core.internal.events.BuildManager.basicBuild(Bui ldManager.java:170)
at org.eclipse.core.internal.events.BuildManager.basicBuild(Bui ldManager.java:201)
at org.eclipse.core.internal.events.BuildManager$1.run(BuildMan ager.java:253)
at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42)
at org.eclipse.core.internal.events.BuildManager.basicBuild(Bui ldManager.java:256)
at org.eclipse.core.internal.events.BuildManager.basicBuildLoop (BuildManager.java:309)
at org.eclipse.core.internal.events.BuildManager.build(BuildMan ager.java:341)
at org.eclipse.core.internal.events.AutoBuildJob.doBuild(AutoBu ildJob.java:140)
at org.eclipse.core.internal.events.AutoBuildJob.run(AutoBuildJ ob.java:238)
at org.eclipse.core.internal.jobs.Worker.run(Worker.java:55)

it is not getting the files to load.
could you please help me with this?

best regards
saad
Re: adding markers to eugenia based editor after applying evl constraints to emfdiff model [message #528679 is a reply to message #528673] Wed, 21 April 2010 13:06 Go to previous messageGo to next message
Dimitrios Kolovos is currently offline Dimitrios KolovosFriend
Messages: 1776
Registered: July 2009
Senior Member
Hi Saad,

You'll need to add the org.eclipse.emf.compare.diff and
org.eclipse.emf.compare.match plugins to the dependencies of your
project and add these two lines at the beginning of your getModels() method:

EPackage.Registry.INSTANCE.put(DiffPackage.eNS_URI,
DiffPackage.eINSTANCE);

EPackage.Registry.INSTANCE.put(MatchPackage.eNS_URI,
MatchPackage.eINSTANCE);

Cheers,
Dimitris

saad bin abid wrote:
> Hello Dimitrios,
>
> Thank you again. I used the following code in EvlStandaloneExample.java
> class to upload the models
>
> @Override
> public List<IModel> getModels() throws Exception {
> List<IModel> models = new ArrayList<IModel>();
>
> String file="
> C:/eclipse-Galileo/eclipse/Sciaml-Test/ie.lero.helloworld.de
> mo.compare/diffmodel/result.emfdiff ";
> models.add(createEmfModelByURI("Model", file,
> "http://www.eclipse.org/emf/compare/diff/1.1", true, true));
> return models;
> }
>
> @Override
> public String getSource() throws Exception {
> return "
> C:/eclipse-Galileo/eclipse/Sciaml-Test/ie.lero.helloworld.de
> mo.compare/diffmodel.evl ";
> }
>
>
> where "result.emfdiff" and "diffmodel.evl" are in runtime enviornment.
> When i run the code using incremental plug-in i get the following error
>
>
> java.lang.NullPointerException
> at org.eclipse.epsilon.examples.standalone.EpsilonStandaloneExa
> mple.getFile(EpsilonStandaloneExample.java:98)
> at org.eclipse.epsilon.examples.standalone.EpsilonStandaloneExa
> mple.execute(EpsilonStandaloneExample.java:45)
> at ie.lero.scicalc.emfdiffmarkers.builder.SampleBuilder.checkXM
> L(SampleBuilder.java:113)
> at ie.lero.scicalc.emfdiffmarkers.builder.SampleBuilder$SampleR
> esourceVisitor.visit(SampleBuilder.java:62)
> at org.eclipse.core.internal.resources.Resource$2.visit(Resourc
> e.java:108)
> at org.eclipse.core.internal.resources.Resource$1.visitElement(
> Resource.java:60)
> at org.eclipse.core.internal.watson.ElementTreeIterator.doItera
> tion(ElementTreeIterator.java:82)
> at org.eclipse.core.internal.watson.ElementTreeIterator.doItera
> tion(ElementTreeIterator.java:86)
> at org.eclipse.core.internal.watson.ElementTreeIterator.iterate
> (ElementTreeIterator.java:127)
> at org.eclipse.core.internal.resources.Resource.accept(Resource
> .java:70)
> at org.eclipse.core.internal.resources.Resource.accept(Resource
> .java:106)
> at org.eclipse.core.internal.resources.Resource.accept(Resource
> .java:90)
> at ie.lero.scicalc.emfdiffmarkers.builder.SampleBuilder.fullBui
> ld(SampleBuilder.java:124)
> at ie.lero.scicalc.emfdiffmarkers.builder.SampleBuilder.build(S
> ampleBuilder.java:93)
> at org.eclipse.core.internal.events.BuildManager$2.run(BuildMan
> ager.java:627)
> at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42)
> at org.eclipse.core.internal.events.BuildManager.basicBuild(Bui
> ldManager.java:170)
> at org.eclipse.core.internal.events.BuildManager.basicBuild(Bui
> ldManager.java:201)
> at org.eclipse.core.internal.events.BuildManager$1.run(BuildMan
> ager.java:253)
> at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42)
> at org.eclipse.core.internal.events.BuildManager.basicBuild(Bui
> ldManager.java:256)
> at org.eclipse.core.internal.events.BuildManager.basicBuildLoop
> (BuildManager.java:309)
> at org.eclipse.core.internal.events.BuildManager.build(BuildMan
> ager.java:341)
> at org.eclipse.core.internal.events.AutoBuildJob.doBuild(AutoBu
> ildJob.java:140)
> at org.eclipse.core.internal.events.AutoBuildJob.run(AutoBuildJ
> ob.java:238)
> at org.eclipse.core.internal.jobs.Worker.run(Worker.java:55)
>
> it is not getting the files to load. could you please help me with this?
>
> best regards
> saad


--
Spread the word: http://www.eclipse.org/gmt/epsilon/spreadtheword
Follow Epsilon on Twitter: http://twitter.com/epsilonews
Re: adding markers to eugenia based editor after applying evl constraints to emfdiff model [message #528766 is a reply to message #528679] Wed, 21 April 2010 17:05 Go to previous messageGo to next message
saad bin abid is currently offline saad bin abidFriend
Messages: 60
Registered: October 2009
Location: Ireland
Member
Hello Dimitrios,
Thanks again for the quick reply. I followed the instructions you mentioned earlier. unfortunately its still not loading the models and i am getting the following errors


Exception in thread "main" java.lang.NullPointerException
at org.eclipse.epsilon.emc.emf.EmfModelResourceFactory.createRe source(EmfModelResourceFactory.java:47)
at org.eclipse.epsilon.emc.emf.EmfModelResourceSet.createResour ce(EmfModelResourceSet.java:23)
at org.eclipse.epsilon.emc.emf.EmfModel.loadModel(EmfModel.java :181)
at org.eclipse.epsilon.emc.emf.EmfModel.load(EmfModel.java:96)
at org.eclipse.epsilon.emc.emf.EmfModel.load(EmfModel.java:90)
at org.eclipse.epsilon.examples.standalone.EpsilonStandaloneExa mple.createEmfModelByURI(EpsilonStandaloneExample.java:95)
at org.eclipse.epsilon.examples.standalone.evl.EvlStandaloneExa mple.getModels(EvlStandaloneExample.java:67)
at org.eclipse.epsilon.examples.standalone.EpsilonStandaloneExa mple.execute(EpsilonStandaloneExample.java:58)
at org.eclipse.epsilon.examples.standalone.evl.EvlStandaloneExa mple.main(EvlStandaloneExample.java:49)

I don't know how to proceed from here. I am sending you the project i am working with on your official e mail address. If you get some time please have a look.

Thank you very much.
best regards
saad
Re: adding markers to eugenia based editor after applying evl constraints to emfdiff model [message #588359 is a reply to message #527828] Sat, 17 April 2010 14:05 Go to previous messageGo to next message
saad bin abid is currently offline saad bin abidFriend
Messages: 60
Registered: October 2009
Location: Ireland
Member
Hello Dimitrios,
Thanks for the reply. As a starting point I am trying to work out with "EvlStandaloneExample". I checked out from epsilon svn. I am running the "EvlStandaloneExample.java", but i am getting the following error

java.lang.UnsupportedClassVersionError: Bad version number in .class file
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(Unknown Source)
at java.security.SecureClassLoader.defineClass(Unknown Source)
at java.net.URLClassLoader.defineClass(Unknown Source)
at java.net.URLClassLoader.access$100(Unknown Source)
at java.net.URLClassLoader$1.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClassInternal(Unknown Source)
Exception in thread "main"


Am i missing something? or if there is some pre setup i need to consider?

best regards
saad
Re: adding markers to eugenia based editor after applying evl constraints to emfdiff model [message #588367 is a reply to message #588359] Sat, 17 April 2010 14:33 Go to previous messageGo to next message
Dimitrios Kolovos is currently offline Dimitrios KolovosFriend
Messages: 1776
Registered: July 2009
Senior Member
Hi Saad,

This sounds like a Java version problem. Which JRE version are you
using?

Cheers,
Dimitris

saad bin abid <saad.softwareengineer@gmail.com> wrote:
> Hello Dimitrios,
> Thanks for the reply. As a starting point I am trying to work out with
> "EvlStandaloneExample". I checked out from epsilon svn. I am running
> the "EvlStandaloneExample.java", but i am getting the following error
>
> java.lang.UnsupportedClassVersionError: Bad version number in .class
> file
> at java.lang.ClassLoader.defineClass1(Native Method)
> at java.lang.ClassLoader.defineClass(Unknown Source)
> at java.security.SecureClassLoader.defineClass(Unknown Source)
> at java.net.URLClassLoader.defineClass(Unknown Source)
> at java.net.URLClassLoader.access$100(Unknown Source)
> at java.net.URLClassLoader$1.run(Unknown Source)
> at java.security.AccessController.doPrivileged(Native Method)
> at java.net.URLClassLoader.findClass(Unknown Source)
> at java.lang.ClassLoader.loadClass(Unknown Source)
> at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
> at java.lang.ClassLoader.loadClass(Unknown Source)
> at java.lang.ClassLoader.loadClassInternal(Unknown Source)
> Exception in thread "main"
>
> Am i missing something? or if there is some pre setup i need to
> consider?
>
> best regards
> saad
>
Re: adding markers to eugenia based editor after applying evl constraints to emfdiff model [message #588370 is a reply to message #527964] Sun, 18 April 2010 12:56 Go to previous messageGo to next message
saad bin abid is currently offline saad bin abidFriend
Messages: 60
Registered: October 2009
Location: Ireland
Member
Hello Dimitrios,
thanks again for the reply. yes i changed the Jre version and it started working now. I have one more question regarding

models.add(createEmfModel("Model", "models/result.emfdiff", "x", true, true));

when i am trying to load the models both the instance and the meta model, I want to know what should i put in "x", which has to be the meta model for the emfdiff model? any ideas how can i actually load the models before i apply the constraints on results.emfdiff?

best regards
saad
Re: adding markers to eugenia based editor after applying evl constraints to emfdiff model [message #588377 is a reply to message #588370] Mon, 19 April 2010 12:29 Go to previous messageGo to next message
Dimitrios Kolovos is currently offline Dimitrios KolovosFriend
Messages: 1776
Registered: July 2009
Senior Member
Hi Saad,

The namespace uri of *.emfdiff models is
http://www.eclipse.org/emf/compare/diff/1.1 As you're running this
through a standalone Java application, please make sure that the EMF
diff EPackage is actually in the EPackage registry before trying to load
the model.

Cheers,
Dimitris

saad bin abid wrote:
> Hello Dimitrios,
> thanks again for the reply. yes i changed the Jre version and it started
> working now. I have one more question regarding
>
> models.add(createEmfModel("Model", "models/result.emfdiff", "x", true,
> true));
>
> when i am trying to load the models both the instance and the meta
> model, I want to know what should i put in "x", which has to be the meta
> model for the emfdiff model? any ideas how can i actually load the
> models before i apply the constraints on results.emfdiff?
>
> best regards
> saad


--
Spread the word: http://www.eclipse.org/gmt/epsilon/spreadtheword
Follow Epsilon on Twitter: http://twitter.com/epsilonews
Re: adding markers to eugenia based editor after applying evl constraints to emfdiff model [message #588493 is a reply to message #528123] Wed, 21 April 2010 12:59 Go to previous messageGo to next message
saad bin abid is currently offline saad bin abidFriend
Messages: 60
Registered: October 2009
Location: Ireland
Member
Hello Dimitrios,

Thank you again. I used the following code in EvlStandaloneExample.java class to upload the models

@Override
public List<IModel> getModels() throws Exception {
List<IModel> models = new ArrayList<IModel>();

String file=" C:/eclipse-Galileo/eclipse/Sciaml-Test/ie.lero.helloworld.de mo.compare/diffmodel/result.emfdiff ";
models.add(createEmfModelByURI("Model", file, "http://www.eclipse.org/emf/compare/diff/1.1", true, true));
return models;
}

@Override
public String getSource() throws Exception {
return " C:/eclipse-Galileo/eclipse/Sciaml-Test/ie.lero.helloworld.de mo.compare/diffmodel.evl ";
}


where "result.emfdiff" and "diffmodel.evl" are in runtime enviornment. When i run the code using incremental plug-in i get the following error


java.lang.NullPointerException
at org.eclipse.epsilon.examples.standalone.EpsilonStandaloneExa mple.getFile(EpsilonStandaloneExample.java:98)
at org.eclipse.epsilon.examples.standalone.EpsilonStandaloneExa mple.execute(EpsilonStandaloneExample.java:45)
at ie.lero.scicalc.emfdiffmarkers.builder.SampleBuilder.checkXM L(SampleBuilder.java:113)
at ie.lero.scicalc.emfdiffmarkers.builder.SampleBuilder$SampleR esourceVisitor.visit(SampleBuilder.java:62)
at org.eclipse.core.internal.resources.Resource$2.visit(Resourc e.java:108)
at org.eclipse.core.internal.resources.Resource$1.visitElement( Resource.java:60)
at org.eclipse.core.internal.watson.ElementTreeIterator.doItera tion(ElementTreeIterator.java:82)
at org.eclipse.core.internal.watson.ElementTreeIterator.doItera tion(ElementTreeIterator.java:86)
at org.eclipse.core.internal.watson.ElementTreeIterator.iterate (ElementTreeIterator.java:127)
at org.eclipse.core.internal.resources.Resource.accept(Resource .java:70)
at org.eclipse.core.internal.resources.Resource.accept(Resource .java:106)
at org.eclipse.core.internal.resources.Resource.accept(Resource .java:90)
at ie.lero.scicalc.emfdiffmarkers.builder.SampleBuilder.fullBui ld(SampleBuilder.java:124)
at ie.lero.scicalc.emfdiffmarkers.builder.SampleBuilder.build(S ampleBuilder.java:93)
at org.eclipse.core.internal.events.BuildManager$2.run(BuildMan ager.java:627)
at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42)
at org.eclipse.core.internal.events.BuildManager.basicBuild(Bui ldManager.java:170)
at org.eclipse.core.internal.events.BuildManager.basicBuild(Bui ldManager.java:201)
at org.eclipse.core.internal.events.BuildManager$1.run(BuildMan ager.java:253)
at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42)
at org.eclipse.core.internal.events.BuildManager.basicBuild(Bui ldManager.java:256)
at org.eclipse.core.internal.events.BuildManager.basicBuildLoop (BuildManager.java:309)
at org.eclipse.core.internal.events.BuildManager.build(BuildMan ager.java:341)
at org.eclipse.core.internal.events.AutoBuildJob.doBuild(AutoBu ildJob.java:140)
at org.eclipse.core.internal.events.AutoBuildJob.run(AutoBuildJ ob.java:238)
at org.eclipse.core.internal.jobs.Worker.run(Worker.java:55)

it is not getting the files to load.
could you please help me with this?

best regards
saad
Re: adding markers to eugenia based editor after applying evl constraints to emfdiff model [message #588509 is a reply to message #588493] Wed, 21 April 2010 13:06 Go to previous messageGo to next message
Dimitrios Kolovos is currently offline Dimitrios KolovosFriend
Messages: 1776
Registered: July 2009
Senior Member
Hi Saad,

You'll need to add the org.eclipse.emf.compare.diff and
org.eclipse.emf.compare.match plugins to the dependencies of your
project and add these two lines at the beginning of your getModels() method:

EPackage.Registry.INSTANCE.put(DiffPackage.eNS_URI,
DiffPackage.eINSTANCE);

EPackage.Registry.INSTANCE.put(MatchPackage.eNS_URI,
MatchPackage.eINSTANCE);

Cheers,
Dimitris

saad bin abid wrote:
> Hello Dimitrios,
>
> Thank you again. I used the following code in EvlStandaloneExample.java
> class to upload the models
>
> @Override
> public List<IModel> getModels() throws Exception {
> List<IModel> models = new ArrayList<IModel>();
>
> String file="
> C:/eclipse-Galileo/eclipse/Sciaml-Test/ie.lero.helloworld.de
> mo.compare/diffmodel/result.emfdiff ";
> models.add(createEmfModelByURI("Model", file,
> "http://www.eclipse.org/emf/compare/diff/1.1", true, true));
> return models;
> }
>
> @Override
> public String getSource() throws Exception {
> return "
> C:/eclipse-Galileo/eclipse/Sciaml-Test/ie.lero.helloworld.de
> mo.compare/diffmodel.evl ";
> }
>
>
> where "result.emfdiff" and "diffmodel.evl" are in runtime enviornment.
> When i run the code using incremental plug-in i get the following error
>
>
> java.lang.NullPointerException
> at org.eclipse.epsilon.examples.standalone.EpsilonStandaloneExa
> mple.getFile(EpsilonStandaloneExample.java:98)
> at org.eclipse.epsilon.examples.standalone.EpsilonStandaloneExa
> mple.execute(EpsilonStandaloneExample.java:45)
> at ie.lero.scicalc.emfdiffmarkers.builder.SampleBuilder.checkXM
> L(SampleBuilder.java:113)
> at ie.lero.scicalc.emfdiffmarkers.builder.SampleBuilder$SampleR
> esourceVisitor.visit(SampleBuilder.java:62)
> at org.eclipse.core.internal.resources.Resource$2.visit(Resourc
> e.java:108)
> at org.eclipse.core.internal.resources.Resource$1.visitElement(
> Resource.java:60)
> at org.eclipse.core.internal.watson.ElementTreeIterator.doItera
> tion(ElementTreeIterator.java:82)
> at org.eclipse.core.internal.watson.ElementTreeIterator.doItera
> tion(ElementTreeIterator.java:86)
> at org.eclipse.core.internal.watson.ElementTreeIterator.iterate
> (ElementTreeIterator.java:127)
> at org.eclipse.core.internal.resources.Resource.accept(Resource
> .java:70)
> at org.eclipse.core.internal.resources.Resource.accept(Resource
> .java:106)
> at org.eclipse.core.internal.resources.Resource.accept(Resource
> .java:90)
> at ie.lero.scicalc.emfdiffmarkers.builder.SampleBuilder.fullBui
> ld(SampleBuilder.java:124)
> at ie.lero.scicalc.emfdiffmarkers.builder.SampleBuilder.build(S
> ampleBuilder.java:93)
> at org.eclipse.core.internal.events.BuildManager$2.run(BuildMan
> ager.java:627)
> at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42)
> at org.eclipse.core.internal.events.BuildManager.basicBuild(Bui
> ldManager.java:170)
> at org.eclipse.core.internal.events.BuildManager.basicBuild(Bui
> ldManager.java:201)
> at org.eclipse.core.internal.events.BuildManager$1.run(BuildMan
> ager.java:253)
> at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42)
> at org.eclipse.core.internal.events.BuildManager.basicBuild(Bui
> ldManager.java:256)
> at org.eclipse.core.internal.events.BuildManager.basicBuildLoop
> (BuildManager.java:309)
> at org.eclipse.core.internal.events.BuildManager.build(BuildMan
> ager.java:341)
> at org.eclipse.core.internal.events.AutoBuildJob.doBuild(AutoBu
> ildJob.java:140)
> at org.eclipse.core.internal.events.AutoBuildJob.run(AutoBuildJ
> ob.java:238)
> at org.eclipse.core.internal.jobs.Worker.run(Worker.java:55)
>
> it is not getting the files to load. could you please help me with this?
>
> best regards
> saad


--
Spread the word: http://www.eclipse.org/gmt/epsilon/spreadtheword
Follow Epsilon on Twitter: http://twitter.com/epsilonews
Re: adding markers to eugenia based editor after applying evl constraints to emfdiff model [message #588537 is a reply to message #528679] Wed, 21 April 2010 17:05 Go to previous message
saad bin abid is currently offline saad bin abidFriend
Messages: 60
Registered: October 2009
Location: Ireland
Member
Hello Dimitrios,
Thanks again for the quick reply. I followed the instructions you mentioned earlier. unfortunately its still not loading the models and i am getting the following errors


Exception in thread "main" java.lang.NullPointerException
at org.eclipse.epsilon.emc.emf.EmfModelResourceFactory.createRe source(EmfModelResourceFactory.java:47)
at org.eclipse.epsilon.emc.emf.EmfModelResourceSet.createResour ce(EmfModelResourceSet.java:23)
at org.eclipse.epsilon.emc.emf.EmfModel.loadModel(EmfModel.java :181)
at org.eclipse.epsilon.emc.emf.EmfModel.load(EmfModel.java:96)
at org.eclipse.epsilon.emc.emf.EmfModel.load(EmfModel.java:90)
at org.eclipse.epsilon.examples.standalone.EpsilonStandaloneExa mple.createEmfModelByURI(EpsilonStandaloneExample.java:95)
at org.eclipse.epsilon.examples.standalone.evl.EvlStandaloneExa mple.getModels(EvlStandaloneExample.java:67)
at org.eclipse.epsilon.examples.standalone.EpsilonStandaloneExa mple.execute(EpsilonStandaloneExample.java:58)
at org.eclipse.epsilon.examples.standalone.evl.EvlStandaloneExa mple.main(EvlStandaloneExample.java:49)

I don't know how to proceed from here. I am sending you the project i am working with on your official e mail address. If you get some time please have a look.

Thank you very much.
best regards
saad
Previous Topic:EglTask broken?
Next Topic:[EOL] Native type not found
Goto Forum:
  


Current Time: Mon Dec 22 20:04:42 GMT 2014

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

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