Re: ANN: Ada source code decorator



Martin Krischik <krischik@xxxxxxxxxxxxxxxxxxxxx> writes:

I think that this a full natural way of mapping Ada <-> UML - After
all 'First and 'Last are called Attributes on both sides. And if you
continue the way of stereotypes then you can map all Ada feature to
UML.

Hmm, yes -- I see your point, though it's certainly not the route I
took with http://coldframe.sf.net/. The difference is because I was
coming from a Shlaer/Mellor OOA viewpoint, and also I'd much rather
have a model that accurately reflects the problem domain
(platform-independent model, PIM) and that tools can translate into
code (possibly via a platform-specific model, PSM).

I certainly haven't achieved that with ColdFrame, which is a framework
generator, and has a lot of vaguely Ada-like stereotypes to support
code generation; for example, <<atomic>>. Well, really that could have
a meaning in a translator to C, but it's hardly part of the
application's subject matter[1], and doesn't make it any easier to
discuss with a client whether you are solving the right problem!

So I'm uncomfortable with the idea of having many stereotypes to allow
you to specify every detail of Ada in a model. Why not just write the
Ada? The model needs to be an abstraction. People may remember Raymond
Buhr's book "System design with Ada", which had a diagrammatic
convention for every aspect of Ada 83 and which I can't imagine helped
anyone develop real software.

XMI which could accurately reflect full Ada would have to be extended;
I know UML can be extended using profiles (ie, stereotypes, tagged
values and the associated semantics), one would suppose that XMI
reflects this.

[1] Of course, if you _have_ to say <<atomic>> it's possible that the
subject matter in hand may be one where it _is_ appropriate to discuss
this sort of thing. It seems to tend to the 'implementation detail',
though.
.