#Simon M:
Thanks for the code snipet, a nice first step!

I think I got it now, resembles a little with ATL.
#Uffe:
Thanks for the link for the code template framework, it is helping a lot. The "MDA Transformations User Guide" is a good source too. This example also helped me:
https://dev.e-taxonomy.eu/trac/wiki/EnterpriseArchitect#qwerty:
About (2), I know that in practice the majority of transformations are built for code generation and I respect your opinion, but I disagree with you and it is not what MDE theory says. One can transform UML to BPMN (e.g. class properties to data objects) or from Archimate to UML (e.g. business information level class to UML class), for example.
Briefely explaining my project:
OntoUML serves to define the context information, i.e. the elements to be perceived ("data objetcs"). E.g. patient, health unit, treatment.
SML serves to define the comprehension of situations, i.e. a situation identification mechanism. E.g. a fever situation reflects the rule of a patient having his body temperature greater than 37, where the patient class with the body temperature attribute is created in SML by the transformation from OntoUML.
After a validation and verification method (with
http://www.menthor.net/) the code can be generated by other transformations, in different "flavors": (i) an adaptation of DRL (Drools Rule Language) with CEP extension and (ii) EPL (Event Processing Language) of Java ESPER. There are numerous theories and theses behind this project, the initial metamodels and transformations were built in EMF with ECore and ATL.
If you are interested in discussing that, I'd be glad to try to show that transformation in the same level does do something. But I don't think here in the forum is the appropriate place, I rather via Skype (id joao.luiz.rebelo.moreira) or Linkedin (
https://br.linkedin.com/in/joão-luiz-rebelo-moreira-a5548418).
- Anyway, thanks for your suggestion! By following the existing transformations (e.g. WSDL and C#), I could advance. However, there is still an issue regarding the package stereotype in the File template. I wrote as:
Package
{
name=%qt%Participants from OntoUML package: %packageName%%qt%
stereotype="SML"
%list="Namespace" @separator="\n\n" @indent=""%
}
The idea is to set the first diagram within the package as a SML diagram, showing the toolbox of SML. But, it creates a UML package diagram (when I open the diagram, the toolbox of UML package appears). In WSDL transformation, it uses stereotype="WSDLnamespace" and the diagram is generated as WSDL (when I open the diagram, the toolbox of WSDL appears). According to EA help, "The Stereotype elements use the Profile name as their namespace.", so I imagine that stereotype="SML" would be the correct way (it is the name of my profile).
- What is the API you mentioned? Sorry if it is a stupid question, I'm starting now with transformations in EA.
- In the transformation editor, how to delete trasnformation types that I created as tests?
Cheers!
Joao