Skip to main content

Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » EMF "Technology" (Ecore Tools, EMFatic, etc)  » Error while programmatically mergin two models
Error while programmatically mergin two models [message #620999] Tue, 09 June 2009 08:45
Josip Maras is currently offline Josip MarasFriend
Messages: 41
Registered: July 2009

Can anyone help me with the following problem:

I'm trying to merge two models in code:

final ResourceSet resourceSet = new ResourceSetImpl();
final EObject model1 = ModelUtils.load
(new File("C:/uml/phpWithAttributes.uml"), resourceSet);

final EObject model2 = ModelUtils.load
(new File("C:/uml/phpWithAttributes1.uml"), resourceSet);

final MatchModel match = MatchService.doMatch
(model1, model2, Collections.<String, Object> emptyMap());

final DiffModel diff = DiffService.doDiff(match, false);

MergeService.merge(new ArrayList<DiffElement>(diff.getOwnedElements()),

I get the following exception: cannot be cast

I would be grateful for any ideas on how to resolve this issue.

Thank you
Previous Topic:compare 2 models in elipse rcp
Next Topic:[EMF Compare] what about cross-references of a merged eObject ?
Goto Forum:

Current Time: Mon Feb 26 12:33:16 GMT 2024

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

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

Back to the top