General (#1) - Transformation problems (#28) - Message List

Transformation problems
 unsolved

Not entirely a mediniQVT question, more of a general QVT problem I'm having.

My situation is as follows: I want to perform a simple model-to-model transformation, where the input and output model use the same meta-model. Within this meta-model, I have the following construction:

<a>

<b>

<one or more objects of type a>

</b>

<c>

<one or more objects of type a>

</c>

<d/>

</a>

So: class a is the superclass of b, c and d. Now b and c can have variables of type a, so, these may also be of b, c and d. I'm using rules like the following one:

relation b2b {
checkonly domain in  b1 : b{};
enforce   domain out b2 : b{};
where { a2a(b1, b2); }
}

This works for the top level classes a, b, c and d, but the 'variable objects' are not evaluated.

My question is: is the structure I'm using for my relation rules a good one for this type of problem, or should I use an other one? If it is correct, how can I convince QVT that the variables also should be evaluated?

  • Message #72

    Is the XML fragment a metamodel representation? do you mean with "variables" class members of metamodel classes? Note that relation b2b is no top level relation, so it must be called from somewhere.

Attachments

No attachments created.