Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » ATL » Error loading file - org.eclipse.m2m.atl.core.ATLCoreException
Error loading file - org.eclipse.m2m.atl.core.ATLCoreException [message #894232] Sat, 07 July 2012 22:28 Go to next message
Fernanda R.F. is currently offline Fernanda R.F.Friend
Messages: 64
Registered: May 2012
Member
Hi,

I'm getting the following error when I try to run an ATL plugin class:

What I need to do to solve it?

org.eclipse.m2m.atl.core.ATLCoreException: Error loading modelos\teste.uml: org.eclipse.emf.ecore.xmi.ClassNotFoundException: Class 'myClass' is not found or is abstract. (file:///C:/atlteste/modelos/teste.uml, 3, 96)
	at org.eclipse.m2m.atl.core.emf.EMFInjector.inject(EMFInjector.java:70)
	at org.eclipse.m2m.atl.core.emf.EMFInjector.inject(EMFInjector.java:84)
	at ativic.ATLclass.loadModels(ATLclass.java:128)
	at ativic.ATLclass.main(ATLclass.java:80)
Caused by: org.eclipse.emf.ecore.resource.impl.ResourceSetImpl$1DiagnosticWrappedException: org.eclipse.emf.ecore.xmi.ClassNotFoundException: Class 'myClass' is not found or is abstract. (file:///C:/atlteste/modelos/teste.uml, 3, 96)
	at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.handleDemandLoadException(ResourceSetImpl.java:315)
	at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.demandLoadHelper(ResourceSetImpl.java:274)
	at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.getResource(ResourceSetImpl.java:397)
	at org.eclipse.m2m.atl.core.emf.EMFInjector.inject(EMFInjector.java:65)
	... 3 more
Caused by: org.eclipse.emf.ecore.xmi.ClassNotFoundException: Class 'myClass' is not found or is abstract. (file:///C:/atlteste/modelos/teste.uml, 3, 96)
	at org.eclipse.emf.ecore.xmi.impl.XMLHandler.validateCreateObjectFromFactory(XMLHandler.java:2244)
	at org.eclipse.emf.ecore.xmi.impl.XMLHandler.validateCreateObjectFromFactory(XMLHandler.java:2235)
	at org.eclipse.emf.ecore.xmi.impl.XMLHandler.createObjectByType(XMLHandler.java:1332)
	at org.eclipse.emf.ecore.xmi.impl.XMLHandler.createTopObject(XMLHandler.java:1468)
	at org.eclipse.emf.ecore.xmi.impl.XMLHandler.processElement(XMLHandler.java:1019)
	at org.eclipse.emf.ecore.xmi.impl.XMIHandler.processElement(XMIHandler.java:87)
	at org.eclipse.emf.ecore.xmi.impl.XMLHandler.startElement(XMLHandler.java:1001)
	at org.eclipse.emf.ecore.xmi.impl.XMLHandler.startElement(XMLHandler.java:712)
	at org.eclipse.emf.ecore.xmi.impl.XMIHandler.startElement(XMIHandler.java:169)
	at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.startElement(Unknown Source)
	at com.sun.org.apache.xerces.internal.parsers.AbstractXMLDocumentParser.emptyElement(Unknown Source)
	at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.scanStartElement(Unknown Source)
	at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(Unknown Source)
	at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(Unknown Source)
	at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next(Unknown Source)
	at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
	at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(Unknown Source)
	at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(Unknown Source)
	at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(Unknown Source)
	at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(Unknown Source)
	at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(Unknown Source)
	at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl.parse(Unknown Source)
	at org.eclipse.emf.ecore.xmi.impl.XMLLoadImpl.load(XMLLoadImpl.java:181)
	at org.eclipse.emf.ecore.xmi.impl.XMLResourceImpl.doLoad(XMLResourceImpl.java:242)
	at org.eclipse.emf.ecore.resource.impl.ResourceImpl.load(ResourceImpl.java:1511)
	at org.eclipse.emf.ecore.resource.impl.ResourceImpl.load(ResourceImpl.java:1290)
	at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.demandLoad(ResourceSetImpl.java:255)
	at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.demandLoadHelper(ResourceSetImpl.java:270)
	... 5 more
Re: Error loading file - org.eclipse.m2m.atl.core.ATLCoreException [message #894328 is a reply to message #894232] Sun, 08 July 2012 08:51 Go to previous messageGo to next message
Ed Willink is currently offline Ed WillinkFriend
Messages: 7655
Registered: July 2009
Senior Member
Hi

I suggest that you search for the instructions for using UML models in
standalone ATL transformations.

Regards

Ed Willink


On 07/07/2012 23:28, Fernanda R.F. wrote:
> Caused by: org.eclipse.emf.ecore.xmi.ClassNotFoundException: Class
> 'myClass' is not found or is abstract.
> (file:///C:/atlteste/modelos/teste.uml, 3, 96)
Re: Error loading file - org.eclipse.m2m.atl.core.ATLCoreException [message #895010 is a reply to message #894328] Wed, 11 July 2012 11:55 Go to previous messageGo to next message
Fernanda R.F. is currently offline Fernanda R.F.Friend
Messages: 64
Registered: May 2012
Member
Thanks, I'll search about it.
Re: Error loading file - org.eclipse.m2m.atl.core.ATLCoreException [message #899294 is a reply to message #894232] Tue, 31 July 2012 11:49 Go to previous messageGo to next message
Emwedish Endargachew is currently offline Emwedish EndargachewFriend
Messages: 27
Registered: April 2011
Junior Member
I am not working with UML models, however I have get similar error while working with ecore metamodels.

I have faced with the same problem and I solved it by using a relative path instead of absolute path.

Give the path from your project. For example if you have a metamodels folder, which contains all your metamodels, in your project then set the path to this path as shown below.

x2y.metamodels.metamodelname = metamodels/metamodelname.ecore

i hope this will solve your problem.

good luck.
Re: Error loading file - org.eclipse.m2m.atl.core.ATLCoreException [message #899461 is a reply to message #899294] Wed, 01 August 2012 00:55 Go to previous messageGo to next message
Fernanda R.F. is currently offline Fernanda R.F.Friend
Messages: 64
Registered: May 2012
Member
Hi Emwedish Endargachew,

Thanks for your suggestion. I'm not sure if I really understood, but as you said I need to change my properties file?

So, for example, my project name is testUML and my metamodels file are into a metamodel folder, then I need to use as:

testUML.metamodel.ABC.ecore = metamodel/ABC.ecore , is it?

Thanks

[Updated on: Wed, 01 August 2012 00:56]

Report message to a moderator

Re: Error loading file - org.eclipse.m2m.atl.core.ATLCoreException [message #899494 is a reply to message #899461] Wed, 01 August 2012 07:46 Go to previous messageGo to next message
Emwedish Endargachew is currently offline Emwedish EndargachewFriend
Messages: 27
Registered: April 2011
Junior Member
Hi Fernanda,

Yeah.

Keep the name from the Plugin and add = metamodel/ABC.ecore.

The plugin will provide you the name of the metamodel relative to the module and you have to add the metamodel path. Then add the = metamodel/ABC.ecore right after that.

For example:
in my case the property file originally contains two metamodel names and then I added the path by my self.
hope you will get what i meant.

best

[Updated on: Wed, 01 August 2012 07:47]

Report message to a moderator

Re: Error loading file - org.eclipse.m2m.atl.core.ATLCoreException [message #900139 is a reply to message #899494] Sat, 04 August 2012 14:24 Go to previous messageGo to next message
Fernanda R.F. is currently offline Fernanda R.F.Friend
Messages: 64
Registered: May 2012
Member
Hi Emwedish Endargachew,

I tried what you suggested, but I'm still getting the same error. I really don't know what could be wrong in it.

Running just the ATL code it works perfectly, but then when I try to run it using the ATL plugin, I'm seeing this error, saying that my class in ATL code wasn't found.

Thanks

Re: Error loading file - org.eclipse.m2m.atl.core.ATLCoreException [message #986579 is a reply to message #900139] Wed, 21 November 2012 03:14 Go to previous message
Ola Batarseh is currently offline Ola BatarsehFriend
Messages: 1
Registered: November 2012
Junior Member
Hi.. were you able to find a solution? coz I am facing the same one as the error below. Any help is appreciated.
Ola

org.eclipse.m2m.atl.core.ATLCoreException: Error loading Model/HybridApproach_102412.uml: org.eclipse.emf.ecore.xmi.PackageNotFoundException: Package with uri 'http://www.eclipse.org/uml2/schemas/Standard/1' not found. (file:///C:/Users/owner/workspace/JavaforATL/Model/HybridApproach_102412.uml, 5320, 116)
at org.eclipse.m2m.atl.core.emf.EMFInjector.inject(EMFInjector.java:70)
at org.eclipse.m2m.atl.core.emf.EMFInjector.inject(EMFInjector.java:84)
at SysML4ArenaPlugin.files.AtlScript.loadModels(AtlScript.java:126)
at SysML4ArenaPlugin.files.AtlScript.main(AtlScript.java:81)
Caused by: org.eclipse.emf.ecore.resource.impl.ResourceSetImpl$1DiagnosticWrappedException: org.eclipse.emf.ecore.xmi.PackageNotFoundException: Package with uri 'http://www.eclipse.org/uml2/schemas/Standard/1' not found. (file:///C:/Users/owner/workspace/JavaforATL/Model/HybridApproach_102412.uml, 5320, 116)
at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.handleDemandLoadException(ResourceSetImpl.java:315)
at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.demandLoadHelper(ResourceSetImpl.java:274)
at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.getResource(ResourceSetImpl.java:397)
at org.eclipse.m2m.atl.core.emf.EMFInjector.inject(EMFInjector.java:65)
... 3 more
Caused by: org.eclipse.emf.ecore.xmi.PackageNotFoundException: Package with uri 'http://www.eclipse.org/uml2/schemas/Standard/1' not found. (file:///C:/Users/owner/workspace/JavaforATL/Model/HybridApproach_102412.uml, 5320, 116)
at org.eclipse.emf.ecore.xmi.impl.XMLHandler.getPackageForURI(XMLHandler.java:2591)
at org.eclipse.emf.ecore.xmi.impl.XMLHandler.getFactoryForPrefix(XMLHandler.java:2422)
at org.eclipse.emf.ecore.xmi.impl.XMLHandler.createObjectByType(XMLHandler.java:1299)
at org.eclipse.emf.ecore.xmi.impl.XMLHandler.createTopObject(XMLHandler.java:1468)
at org.eclipse.emf.ecore.xmi.impl.XMLHandler.processElement(XMLHandler.java:1019)
at org.eclipse.emf.ecore.xmi.impl.XMIHandler.processElement(XMIHandler.java:87)
at org.eclipse.emf.ecore.xmi.impl.XMLHandler.startElement(XMLHandler.java:1001)
at org.eclipse.emf.ecore.xmi.impl.XMLHandler.startElement(XMLHandler.java:712)
at org.eclipse.emf.ecore.xmi.impl.XMIHandler.startElement(XMIHandler.java:169)
at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.startElement(Unknown Source)
at com.sun.org.apache.xerces.internal.parsers.AbstractXMLDocumentParser.emptyElement(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.scanStartElement(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(Unknown Source)
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(Unknown Source)
at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(Unknown Source)
at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(Unknown Source)
at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(Unknown Source)
at javax.xml.parsers.SAXParser.parse(Unknown Source)
at org.eclipse.emf.ecore.xmi.impl.XMLLoadImpl.load(XMLLoadImpl.java:181)
at org.eclipse.emf.ecore.xmi.impl.XMLResourceImpl.doLoad(XMLResourceImpl.java:242)
at org.eclipse.emf.ecore.resource.impl.ResourceImpl.load(ResourceImpl.java:1511)
at org.eclipse.emf.ecore.resource.impl.ResourceImpl.load(ResourceImpl.java:1290)
at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.demandLoad(ResourceSetImpl.java:255)
at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.demandLoadHelper(ResourceSetImpl.java:270)
... 5 more
Previous Topic:ATL transformation programming in java code
Next Topic:Launch transformation by java returns different output compared to atl run
Goto Forum:
  


Current Time: Thu Apr 25 17:52:46 GMT 2024

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

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

Back to the top