Writer Templates

Back in Florida!!!


This month I finally had the chance to fly to Florida again. Long time no see! The IBM Think was in Orlando, and I needed to be there.
So I booked the flight, and on a Friday, I took off to fly to Orlando via Boston.
The plane took off late but would still arrive early, so I could leave the airport in Boston and meet with an old I-Logix friend who still works for IBM.
For a few months, I have had a fantastic feature called “Global Entry.” That means you are allowed to enter the USA with just your passport. There is a separate entry with Electronic Passport Reading Machines.
And… it works like a charm. I’m in within seconds. No more standing in line… OK, OK… also, no more stamps. But I can live with that.

This awesome feature comes with another real cool option: TSA Pre-Check. That means: no more unpacking laptop, no more shoes and belt off.
So.. I’m happy. This meant I was out of Boston no more than 5 minutes after the plane landed. Very cool.

We went to a place called “Legal Seafood”. Well chosen name, all was legal 😉 Very good food!

After 3 hours, it was time to go back and catch the plane to Orlando. As always, I am surprised by how big the USA is…

Another 2.5-hour flight brought me to sunny Orlando. It was not so sunny anymore; it was late. So I picked up my rental and went to my hotel to catch some sleep.
Luckily I had already slept on the airplane. Otherwise, it would’ve been a long, long day. I’m not used to that anymore…


I received a question that I’d like to share with my readers. It was from another old I-Logix friend who now works for another company but is still using Rhapsody.

The question was

The Rhapsody C, C++ and Java code generators allowed you to add Requirements comments to generated code


Is there anyway to change the way the requirement comment gets formatted? 

We have some functionality in Polarion whereby if you checkin source code to your SCM system, we have a way of linking parts of that source code to Polarion work-items. 

The problem is, our source code parser requires a certain format for the comment … hence my question if its possible to customize the way Rhapsody produces the requirements comment. 

So far it just seems to do a // Realizes requirement NAME


Of course, you can! Rhapsody wouldn’t be Rhapsody if there wasn’t an intelligent way of doing this.

It’s called: Writer Templates. They are properties that tell the code generator what it needs to generate.

So I made a very small model, 1 Requirement, 1 Class with a “trace” dependency to that requirement and 2 configurations. One without changes and one wit han adapted Writer Template.

This is how the code looks with and without:

You can download it here:

Back to work…

After the Think, I had a few days left to go to Fort Myers and enjoy Florida. 35º and sun, sun, sun…. Of course also seafood, unsweetened ice tea, and beach. And destruction. Yes. The last hurricane really left a lot of damage. Terrible to see.

When you read this, I’m already back. Flew back from Fort Myers via Atlanta to Schiphol. Everybody keeps telling me that it’s not cold… But I think different.

Have fun working with Rhapsody and I hope spring finally turns up in Europe…

Walter van der Heiden walter@sodiuswillert.com

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.