How do I create a meta model for a model-to-model transformation?

modeling
uml

#1

Hey there.

I’d like to do a model-to-model transformation. The target model would be UML activity diagrams, the source model is a rather obscure model and I’d have to create a meta model first. Both models are quite similar, so I’m sure that there shouldn’t be any huge problems.

However, I was wondering if Visual Paradigm is the right tool for me? Here is what I’d like to do: Provide an input diagram (in the form of a JSON or XML file) and generate an UML activity diagram based on that input. Is that something I can do in VP? If yes, how would I create my meta model for the source model?

Thanks in advance


#2

You may use XML Importer + Transformation to import your data + convert them to be an Activity diagram.
(But we just find a bug when prepare the following sample, and the bug is just fixed, the patch may be available in few days.)

How to do it:

— Preparation —

  1. Prepares an XML to import your data to be VP’s GenericModel and GenericConnector.

  2. Creates a DataTable to define your model type, properties.
    And define the transformation schema of your model types.

  3. Creates a dummy Activity Diagram to define the transformation schema of activity diagram.

  4. Connects your 2 transformation schema.

— Operation —

  1. Imports XML to create your meta-model into VP.
  2. Performs transformation from your DataTable to an ActivityDiagram

How to do it (with image description):

— Preparation —

  1. Prepares an XML to import your data to be VP’s GenericModel and GenericConnector.

  2. Creates a DataTable to define your model type, properties.


    And define the transformation schema of your model types.

    (you can click the top-right X button to close the transform schema editing)

  3. Creates a dummy Activity Diagram to define the transformation schema of activity diagram.


    (you can click the top-right X button to close the transform schema editing)

  4. Connects your 2 transformation schema.

— Operation —

  1. Imports XML to create your meta-model into VP.

  2. Performs transformation from your DataTable to an ActivityDiagram


PS:
Sorry, the above solution is quite complex.
(In fact, I never try to use DataTable to define a ‘relationship’. At least, on this solution, I haven’t try to define the generic connector is connected between which model types. And I am not sure can it be defined in the Data Table…)

On another hand, there is a simply solution that, you prepare an XML to specify the Action, ControlFlow, etc… directly.
In this solution, you don’t need to learn how to use the transformation schema. But you need to learn more details on the XML content of Activity Diagram & its model elements.


#3

Peter this is fascinating! Is there a predefined Metamodel for DoDAF? If UAF from OMG would be nice as well.

Or a little tutorial on how to create my own…


#4

Hi jghass,

Sorry that there is no predefined metamodel for DoDAF or UAF right now.

Best regards,
Jick Yeung


#5

Peter, thank you so much. This is amazing, your effort is much appreciated. I’d have never expected such a detailed answer, this helps me A LOT. Thank you!!