thanks. Have been puzzling about how to get it work, but it does now.
I first used the andromda.jar of version 2.01a but that had a bug in it. With the final 2.03 it all worked fine. This is the code I added to make a ValueObject implement generalization:
import java.io.Serializable;
#set ($generalization = $transform.getGeneralization($class.id))
#if (!${generalization})
#set ($extendtag = "")
#else
#set ($parentClassName = ${generalization.getName()})
#set ($parentClassNamePackage = $transform.findPackageName($generalization))
#set ($parentClassFullName = $transform.findFullyQualifiedName($generalization))
#set ($extendtag = "extends $parentClassName ")
#if ( $packagename != $parentClassNamePackage )
import ${parentClassFullName};
#end
#end
Thanks,
regards Jan.
[EMAIL PROTECTED] wrote:
yes you can access inheritance and interface information.
In UML inheritance is called generalization and interfaces are called abstractions. I don't have access to my computer or source code right now, I am travelling, but there should be methods on the script helper class called something like: getGeneralizations getAbstractions
or something similarly named. Just remember that these methods might actually be returning the 'generalization object' that connects the class to it's superclass as opposed to the actual superclass. If that is the case then you will have to first get the 'generalization' object it will then have something like a parent and a child.
-- Original Message -- From: Jan Kester <[EMAIL PROTECTED]> To: [EMAIL PROTECTED] Subject: [Andromda-user] inheritance Date: Sat, 30 Aug 2003 10:34:14 +0200
Hello
Does andromda recognise inheritance relations? That is, I would like to
add a inheritance relation in poseidon and use it in one of my templates. The templates would have to find the inheritance inside the
$class object. So far I have seen that the class contains a collection
of dependencies and of associations. Is the inheritance in there?
Regards, Jan
-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
_______________________________________________
Andromda-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/andromda-user
------------------------------------------------------- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf _______________________________________________ Andromda-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/andromda-user
