Umple is a technology for model-oriented programming. It merges the concepts of programming and modeling by adding modeling abstractions directly into programming languages.

Currently Umple supports Java, PHP and Ruby as base languages. It adds UML attributes, associations and state machines to these languages.
For example, the following Umple code specifies two classes linked by an association.

class Participant {
   String name;
   Integer participantID;
   * -- * Activity registration;
}

class Activity {
   String description;
   Date activityDate;
}

In the above example, the base language methods have been left out. However, methods in any of the three base languages would be embedded to manipulate the associations and attributes.

Umple supports a range of other features, such as immutability, keys, aspect-oriented code-injection, mixins, and singleton objects.

There is an on-line environment to explore Umple at http://cruise.site.uottawa.ca/umpleonline/ . The screenshot below shows this in action. A developer edits the Umple textual language, and the corresponding UML class diagram almost immediately changes to reflect the current state of the Umple textual code. A developer can edit the diagram, and the textual code is also automatically changed. The above URL also contains links to download the Umple Eclipse plugin.

Umple is designed with two kinds of developers in mind. The first is the masses of developers who currently work only with textual code. Umple allows incremental adding of modeling constructs to existing code. The developer can modelize or, as we would say umplify their code in baby steps, until their application is fully model-driven.

On the other hand, Umple encourages developers to plunge directly into model-first development, whether their previous experience has been as coders or as users of graphical UML tools.

We have found UmpleOnline works very well in the classroom. Prior to Umple, we had a hard time convincing students of the benefits of modeling. With Umple, we instantly show the consequences of modeling decisions. Students seem to ‘get it’, since their models have been much better since Umple was introduced. Several other professors have also started using Umple recently.

Umple is designed to eliminate ‘fear of a new language’ that impedes developers from taking on modeling. Umple can be seen as simply a pre-processor, and developers are familiar with these. All the skills in base language development transfer over to Umple since you can compile base language code with almost no changes: The Umple compiler will simply pass base language code through to the base language compiler.

A final point is of particular importance: Umple eliminates the concept of ‘round tripping’. There is never any need to edit generated code, since any desired effects can be achieved either directly in the model, in the passed-through methods or in the aspect-oriented code injections.

Umple can be and is being used today. Its compiler generates robust base language code for class diagram concepts and for simple state machines. In fact Umple is written in itself. We challenge all model-driven tool and language developers to follow our leand and generate their own systems using their own technology. That said, Umple is still under development. Don’t expect good compiler error messages, or debugger support yet. Those things are coming. To speed that process up we are cleaning up Umple’s documentation with the plan to open source it by the end of 2010. You can subscribe to Tim Lethbridge’s blog for ongoing news about Umple. I will also let Jordi Cabot know of significant changes, so he can inform you too.

 

Pin It on Pinterest

Share This