Eating the world through DSML

I borrowed this blog entry title from an interesting post in the January 2016 Eclipse Newsletter titled “How to Eat the World with DSLs.”

In that article, the author makes many good point about DSL, such as creating a language with which the users are already familiar and abstracting the more complex aspects of coding (a payroll system implemented in Excel sheet in this case) to facilitate the domain expert’s job.

The same approach can be used when dealing with the complexity of modeling. UML is known to be rather complex, but a using a DSML to represent your domain will simplify the work of your developers. Ericsson presented a good example of this at EclipseCon Europe 2014: “UML or DSML? You can now have both with Papyrus 1.0!

An advantage of using a UML-based DSML, at least in the Systems Domain, is that existing analysis tools can be used on the underlying UML model to do common functions, e.g. traceability. Using UML as the base for your DSML also allows you reuse parts of the UML that would make sense in your domain (e.g., sequence diagrams are already available for free). For other aspects, such as collaborative modeling, you would still need to do some toolsmith work to be able to present the results in the context of your DSML instead of UML. Domain experts should not have to understand the underlying implementation and must be kept at their level of abstraction!

The capability to author DSMLs is already available within Papyrus and will continue to evolve and improve as part of the newly created Papyrus Industry Consortium.

And even if you do not feel like you need to base your DSML on UML, there are other Eclipse offerings, such as Xtext (mentioned in the article referenced above, textual DSL) and Eclipse Sirius (graphical DSML based on its own metamodel).

Within Eclipse PapyrusRT, we already use Papyrus’ DSML capabilities to implement the graphical UML-RT modeling language. We are now investigating combining this with an Xtext-based representation of UML-RT to blur the line between graphics and text. Our take is that you should not limit yourselves to only textual or graphical representation – some things are easier in one or the other and, sometimes, a mix of both can be better!

With a good infrastructure to support it, DSMLs are the modeling approach of the future and is available now. You should take a closer look!

Advertisements