Generate code from Business Process Model and Notation (BPMN) with androMDA - uml

I know that AndroMDA generate code from UML model,
my question is:
it is possible to generate code from BPMN model (Business Process Model and Notation) with androMDA (i.e create a new cartridge which support BPMN)?

Common practice is not to generate code for BPMN model, but interpret it, Take a look on jBPM cartrige for AndroMDA.

Related

Using a UML diagram to show a project that involves different programming languages

I'm currently designing the UML diagram for a project that involves the usage of MySQL (for data storing) and Java (for data "presentation"), my question is, is it correct to use a single UML diagram in a project that involves multiple languages? and also, do I need to explicitly show which part "belongs" to each language?
Even though I know UML is a generic representation I had this question because I plan to do all the data processing in the server, and for that I have a class in the package "datos" (data) but for databases I have always used the ER model and also, the class "Reportero" has a bunch of methods that are "symbolic" because their functionality will be achieved with Queries.
Class in the UML diagram I'm referring to
Thank you in advance!
In general you need to decompose your system into subsystems or components, which you can realize using different languages. The pure UML way is using deployment diagrams, that models the deployment to hardware or to runtime environements like application servers. A less UMLish way is using custom stereotypes at the components that you have defined.
More specifacally, you are asking for a MySQL. In a UML model you model static parts of your system, their properties and interactions based on them. But you usually dont model databases. So what you can do using UML is object oriented analysis, which gives you classes that can represent the entities in your database. But when you say you have class, which operations are realized by queries, you still have something implemented in your language that triggers the execution of the query; in that case I would either define a stereotype used for classes or for operations indicating that the contained operations or the operation has no own logic but just calls the queries.
Further you should get familar with the term model and diagram :-)
UML is not about diagramming. It is about models - and communicating them to humans by means of diagrams.
What you do in more complex systems is to split them into sub-domains and package them in a meaningful way. In the same way you would create individual diagrams showing static and dynamic system aspects. In your concrete case you could show the database design separate from the runtime design. However, it is also possible to mix both in overview diagrams.

Does every class in the design model have to be present in the domain model?

I have doubt regarding design model.Does every class in the design model have to be present in the domain model?
Object modeling is best done as an iterative process, so start with whatever (simple) design you think meets your current requirements and build upon it as you learn more about your domain.
The question is not well explained even if the subject is important.
UML is an object approach like Java codding while domain modelling is related to databases structure. UML is not therefore the same as domain modelling.
Having said that JD5 and later allows ORM annotations in the code. It means that at object level you can also think about databases using Hibernate annotations directly in your java code. EclipseUML is lived synchronized with the Java code but also with ORM annotations. It means that all ORM annotations written in the code are updated in the class diagram as well as in the model and each class diagram annotations change is updated in the code.
It means that UML and domain modelling are now unified using standard ORM annotation.

Creating a meta model using UML convention and creating a data model out of it

Sorry if the question sounds too vague. I will improve based on your feedback.
I have managed to prepare a UML model of a problem domain. This is essentially a class diagram describing class attributes and aggregation relationships amongst classes. Intention now is to fill data.
For example, class-A aggregates N instances of Class-B. I would like to create a data model that has data for one instance Class-A and 5 instances of Class-B.
Basically, data pertaining to this meta model is available in a document (e.g. xls, framemaker) and it should be possible to read the source and populate the data model.
Are there tools that will let me create this data model? Please advise.
You have two options to creates your database model from our UML model.
You can use the UML model and then add a code generator to generate the database then finally reverse it with a database modeling tool such as erwin.
Another approach is to use the database modeling profile inside your UML model. It means that ypu model and add database stereotype related to java ORM.
Both works pretty well.

UML Diagram Examples of Popular Software

Where can one find thorough documentation and UML diagrams of popular software? I've searched around and have found very few examples. I'm sure most of this documentation will be private for enterprises, but maybe there are a few links around?
Cheers!
You will not find such a document except if you work at MOF level like Omondo EclipseUML does.
There is also a dilemma in UML.
Should UML just be a view of a problem and therefore only covers a specific view of a software or should it cover the full project ?
UML has been stuck during many year by Model Driven Development which is a code generation from a model. It is therefore one shot modeling which could not be reused. The problem is that to complete a project you can not just generate a code from a model you need to complete the code by hand !! This is why MDD and UML is useless.
Your question is really good because why don't we just use an existing model which is specific to a business, arrange the model as much as needed and then generate the code ?
I think reusable models do not exist because too many transformation layers between graphical model, views, metamodel , MOF etc.....
Projects would be developped 10 times faster if reusable models and architecture would be robust. So why no free model exist today ? It is always question of money :-)
If no money then you need to use open source but open source is crap MDD. It is not a full model but just a specific view of a problem while you need full project to generate usable code !!
Omondo has done a courageous initiative to cover the full project by reversing all model information inside a MOF model and then giving views of the model using multiple class diagrams. Class diagram is live syncrhonized with the code and MOF. The problem is that you need to pay for the tool and consulting companies are selling their business models build on the top of MOF. The UML tools have less and less value but models could be a lot more profitable market in the near future.

Generate UML from a conceptual data model

I have an conceptual data model (Relational model) created using powerAMC for my database but i wanted to generate DAO from it using acceleo and for that i need it in UML , is there a way to generate UML from a conceptual data model model ?
Acceleo can generate code from any models defined with any EMF based metamodel. The UML project of the Eclipse Foundation defines an UML metamodel based on EMF so that users can create UML models based on EMF and Acceleo can thus generate code from those models.
If you want to use another metamodel, you can do it, so if you want to create a metamodel that matches more closely your data structure, feel free to do so. As an example, you can see here a metamodel that I have created of the Scala language and my generator uses models defined from this metamodel to generate the code. You can find an example of a generator using this metamodel here. You can see in this example that the Acceleo generator is defined on my scala metamodel "http://github.com/sbegaudeau/acceleo/scalametamodel/2011/01" (contrary to an Acceleo generator that would be defined on UML that would be using the standard UML metamodel "http://www.eclipse.org/uml2/3.0.0/UML") and I can manipulate in Acceleo some concepts from this metamodel directly like traits (if you are familiar with Scala).
So you can:
create a metamodel that matches your concepts
create a small converter in java to create an EMF model (instance of your metamodel defining the concepts of your database) and then transform the data in your database to an EMF model that you just have to save.
use Acceleo with your models :)
Regards,
Stephane Begaudeau
Disclaimer: I am the leader of Acceleo.
PowerAMC has a data model which is not object like UML. It is therefore impossible to transform it to UML.
If you have directly the generated database then you can create the UML model from the code but not from database modeler.

Resources