[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Newsgroup Home]
[news.eclipse.modeling.gmf] Alternative types of top node elements

Hi there,

I want to do something very simple:

I have two objects in my domain model: A State and a CompartmentState,
where the CompartmentState extends the State. Now the CompartmentState
aggregates States in a "myStates" relation, hence it can contain States
and CompartmentStates recursively, modeling hierarchy.

The diagram extends CompartmentState, hence it can contain both types.

How do I set this up correctly in the mapping?

1. I cannot create two TopNodeReference for both State and
CompositeState, because I have only one aggregation "myStates". Hence I
get an error message if I choose the same Containment Feature:
"Phantom nodes that are not targeted by a link mapping exist".

2. I cannot create a single TopNodeReference to State (which gets
extended by CompartmentState), because only the latter has a Child
Reference to "myStates".

3. Next try would be to create a second aggregation from
CompartmentState to CompartmentState recursively to get two distinct
aggregations, but this is not exactly what I want...

How to do it?

Cheers,
Hauke