Tid Bit TechieVarta

Icon

Another TechieVarta

Archive for the ‘Software Design’ Category


Generating UML2 Sequence Diagram: SDEDIT

Friday, June 13th, 2008

As software designers we always need to create Sequence Diagrams for documents. Some documents can use have lots of variations of sequence diagrams. My documents are normally written in MS-Word and use Visio for diagrams. Instead of using Visio’s built-in UML stencils (which are awfully difficult to use) I have always used stencils from this site. These stencils are significantly easier to use. Still generating many sequence diagram can take a lot of time.

After some research I  found SDEDIT at Sourceforge. This tool is just fantastic. It is fast, powerful and customizable.The tool has its own scripting language. The tool has a split window GUI. You type the script in the bottom half the the diagram immediately appears in the top window. It is possible to export the sequence diagram in variety of graphics formats.

Also, it is possible to run the tool from command line. So just create the sequence diagrams on in various text files and run sdedit to generate various png or whichever format you like and embed in your document.

Visio diagrams are nice since they provide a way to embed the actual Visio object inside the document using OLE. This implies that everything used to create the document is in a single file. This has advantage with with respect to management of the document. I am not an OLE expert but it should be possible to provide an OLE wrapper around the sdedit. In the meanwhile I will settle with including contents of the script file as an icon inside the document.