Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » Compare » Java Packages Comparison(Need help to use EMF Compare to find the diffs between Java Packages)
Java Packages Comparison [message #521903] Fri, 19 March 2010 08:55
mRoby88 is currently offline mRoby88Friend
Messages: 4
Registered: March 2010
Junior Member
Dear All,
I'm developing an Eclipse Plug-in that needs to be able to compute the diff between Java Source files as well as Java Packages, as "Compare with Each other" Eclipse's functionality does.
Can EMF Compare help me? I installed in Eclipse all the materials as well as downloaded all the CVS projects via the *.psf file but I'm not able to use it as I want to.
I already take a look at the Stand-Alone project, as suggested in many threads, but it does not help since I reported errors while using it.

Loading resources.

org.eclipse.emf.ecore.resource.Resource$IOWrappedException: Content is not allowed in prolog.
	at org.eclipse.emf.ecore.xmi.impl.XMLLoadImpl.load(XMLLoadImpl.java:201)
	at org.eclipse.emf.ecore.xmi.impl.XMLResourceImpl.doLoad(XMLResourceImpl.java:180)
	at org.eclipse.emf.ecore.resource.impl.ResourceImpl.load(ResourceImpl.java:1494)
	at org.eclipse.emf.ecore.resource.impl.ResourceImpl.load(ResourceImpl.java:1282)
	at org.eclipse.emf.compare.util.ModelUtils.load(ModelUtils.java:320)
	at org.eclipse.emf.compare.util.ModelUtils.load(ModelUtils.java:218)
	at ExampleLauncher.main(ExampleLauncher.java:64)
Caused by: org.xml.sax.SAXParseException: Content is not allowed in prolog.
	at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.createSAXParseException(ErrorHandlerWrapper.java:195)
	at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.fatalError(ErrorHandlerWrapper.java:174)
	at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:388)
	at com.sun.org.apache.xerces.internal.impl.XMLScanner.reportFatalError(XMLScanner.java:1414)
	at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl$PrologDriver.next(XMLDocumentScannerImpl.java:1039)
	at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(XMLDocumentScannerImpl.java:648)
	at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:510)
	at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:807)
	at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:737)
	at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:107)
	at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1205)
	at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(SAXParserImpl.java:522)
	at javax.xml.parsers.SAXParser.parse(SAXParser.java:395)
	at org.eclipse.emf.ecore.xmi.impl.XMLLoadImpl.load(XMLLoadImpl.java:181)
	... 6 more



Can someone, please, provide me a snippet of code that can help me comparing two Java Packages?

The plug-in displays a pop-up menu when in the Package Explorer the user selects two resources.
- Comparing files is done using org.eclipse.compare
- Comparing Packages is not implemented so far.

I'd like to use EMF compare to do that. Seems interesting but I cannot manage to have it working. The idea is to have the user to select two packages (possibly two different versions of the same package) and then compute the diff over all the classes belonging to that package.

Best regards and thank in advance,
Roberto M.
Previous Topic:org.eclipse.compare for Java Packages
Next Topic:Java Pseudo conflict woes
Goto Forum:
  


Current Time: Sat Apr 20 01:56:09 GMT 2024

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

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

Back to the top