Wednesday, 28 September 2005
Having spent some time in the VS2005 environment, I can say the following about DSLs:
 
A domain-specific language (DSL) is a language designed to be useful for a specific task in a fixed problem domain, in contrast to a general-purpose language. DSLs are gaining popularity in the field of software engineering to enhance productivity, maintainability, and reusability of software artifacts, and enable expression and validation of concepts at the level of abstraction of the problem domain.
 
Using domain-specific languages, one can build customized modeling tools and essentially define a new modeling language and implement it very simply. For example, a specialized language may be used to describe a user interface, a business process, a database, or the flow of information, and then used to generate code from those descriptions.
 
I built a (small) DSL for modeling application integration scenarios, which is always an issue in the IT business world. First, I defined all of the specific domain model terms used in application integrations scenarios such as XML messages, source destination applications, XSL maps, business units, protocols, business rules, etc. Then I described the designer definitions that make up the visualization tool. Once the meta data was defined in a supplied Visual Studio template, you build the solution and another instance of Visual Studio fires up with your visual designer implemented.
 
You then use the visual designer you just created to draw/model the application integration scenario and when you run this solution, it code generates the solution.
 
Of course, I have left out a lot of detail and it was not easy the first couple of times. I have left out a set of code generators, which take a domain model definition and a designer definition as input, and produce code that implements both of the components as output. The code generators also validate the domain model and designer definition, and raise errors and warnings accordingly. But eventually, you get the hand of it.
 
Think of it this way, DSL is a tool for building tools :-) For example, anyone that has used the Class Designer in Visual Studio is using a DSL outputted visual designer, specifically designed for building classes.
 
The process has been quite the learning experience for me and has proven to be very enlightening. I am an old guy, been writing code for 15 years. Quite frankly, I dont give a hoot about which programming language I use cause I see them all as being the same, some better than others, but still hand crafting code. I dont want to hand craft code anymore every time I get involved in a software development project I a) have done it before and b) oh man, this is going to take 6 months of grinding it out. In other words, its gonna hurt.
 
I see DSLs as a evolution in our software industry to use higher level abstractions in the way of visual designers to so that I can spend time designing the solution and have most of the infrastructure code generated for me, that I otherwise would have to grind it out.
 
If you are interested in more information about DSLs and dont mind reading it from Microsoft, download the DSL Toolkit and have a read of the documents at: Microsoft Domain-Specific Language (DSL) Tools
Wednesday, 28 September 2005 03:06:07 (Pacific Standard Time, UTC-08:00)  #    Comments [0]
© Copyright 2008 Mitch Barnett - Software Industrialization is the computerization of software design and function.

newtelligence dasBlog 1.9.6264.0  Theme design by Bryan Bell
Feed your aggregator (RSS 2.0)   | Page rendered at Wednesday, 26 March 2008 18:19:12 (Pacific Standard Time, UTC-08:00)