On Fri, Mar 27, 2009 at 8:02 AM, Andreas Rueckert <[email protected]> wrote:

> I checked the SQL-Module a bit last night and wanted it to create code for a 
> database

Don't forget the DB module.  It's received a lot more attention
recently than the SQL module.

> Problem: when you generate code, you have to select the classes for the CG 
> manually. I thought, it
> would be nice, if a module would recognize the classes, it can generate code 
> for, by itself.
> So I propose a minor extension to the CodeGenerator interface. Just a method, 
> that checks, whether
> a class 'suits' this module and returns true or false. So in our case, the CG 
> dialog could loop all classes,
> pass them to all the modules, and the SQL module would check, if the class 
> has a stereotype, that fits
> and returns true for those classes. Other modules could check (as an 
> example), if there's already some
> code in the method bodies that matches their language.

Couldn't this be implemented as an option internal to the module
itself?  Then the user could say "generate all classes" and the module
could filter those that it knows how to generate.

> I think, that it would be a useful extension, but it would break all module 
> with CG, I guess...

If it did turn out to be something requiring an API change, there are
ways to do it without breaking existing modules.  Something which
broke all existing modules would be very bad.

Tom

------------------------------------------------------
http://argouml.tigris.org/ds/viewMessage.do?dsForumId=450&dsMessageId=1443318

To unsubscribe from this discussion, e-mail: 
[[email protected]].
To be allowed to post to the list contact the mailing list moderator, email: 
[[email protected]]

Reply via email to