Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » Epsilon » Merging fragments
Merging fragments [message #543267] Mon, 28 June 2010 21:28 Go to next message
Ferghal Smyth is currently offline Ferghal SmythFriend
Messages: 16
Registered: May 2010
Location: Clare, Ireland
Junior Member
Hi,

I'm having trouble merging model fragments together.

@greedy
rule MergeFragments 
	merge l : Source!ContextRootNode
	with r : Source!FMNode
	into t : Target!Feature {
	
t.name := l.child.name;
t.child := l.child.child;

}


The models are fragments of an overall model that must be combined. In the first fragment is the FMNode or Feature A.
In the second fragment are the features B and C. The context node holds information of where the models should be joined. and says the second fragment of B and C should be made the children of feature A.

This would result in the a model that looked like A->B->C.

I'm not really sure how to assign the children to become the children of the new feature in t or is there some way to just copy r and all its current children and just add in the new features.

Thanks,

Ferg



Re: Merging fragments [message #543531 is a reply to message #543267] Tue, 29 June 2010 17:21 Go to previous messageGo to next message
Dimitris Kolovos is currently offline Dimitris KolovosFriend
Messages: 911
Registered: July 2009
Senior Member
Hi Ferg,

I'm not sure I fully understand your question. Could you please put together a zip containing the metamodels, sample input models and the expected composed model and send it to me at dskolovos gmail com so that I can have a closer look at this?

Cheers,
Dimitris
Re: Merging fragments [message #590431 is a reply to message #543267] Tue, 29 June 2010 17:21 Go to previous message
Dimitris Kolovos is currently offline Dimitris KolovosFriend
Messages: 911
Registered: July 2009
Senior Member
Hi Ferg,

I'm not sure I fully understand your question. Could you please put together a zip containing the metamodels, sample input models and the expected composed model and send it to me at dskolovos gmail com so that I can have a closer look at this?

Cheers,
Dimitris
Previous Topic:Merging fragments
Next Topic:[eol] problem with creating a native java String
Goto Forum:
  


Current Time: Sun Nov 23 06:09:23 GMT 2014

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

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