I'm using version 3.0M3
Thank you for your answer Manuel, I'll try it as soon as possible.
Regards
Bruno
Manuel Blechschmidt dijo lo siguiente el 11/09/2004 15:53:
Hi again,
I'm trying to implement bitemporal tables with the two layer
specification, separating Valid-
Times and Transaction-Times each ones in their own classes.
I've created a Bitemporal Stereotype, and i assign it to the
association between the two
classes.
Which version of andromda are you using?
While modifying the HibernateEntity.vsl template I'm getting an error
that is turning me
crazy...
I've done a velocimacro with the following signature #macro (
isInHierarchie $aClass
$aStereotype $found)
This recursive method finds if one of the classes in the hierarchie of
the class passed as first
parameter has an asociation labeled with the stereotype passedas the
second parameter.
The third parameter is an outgoing boolean, also used as stop-condition
in the recursion.
This applies only to version 3.0 of andromda:
You should do this stuff in the Metafacade. Unfortantly there isn't
already a Metafacade to do this so I will explain how to create one.
So first you have to add a new class with your needed function to the
Metafacede Model of the hibernate cartridge.
You can create in the class new methods like isInHierarchie with your
needed parameter.
You find the metafacade model in
<andromda-src-dir>/cartridges/andrmda-hibernate/src/uml/HibernateMetafacadeModel.xml.zip
You should call the new class HibernateEntityFacade. The class must
extend or in uml is generalize by EntityFacade. The EntityFacade you
will find in the
<andromda-src-dir>/\cartridges\andromda-meta\src\uml\MetaMetafacadeModel.xml.zip
You have to link or import this file in Magic Draw.
Then you have to regenerate the metafacade:
cd <andromda-src-dir>/cartridges/andromda-hibernate/
maven clean
maven andromda:run
Then you have to tell andromda when wo use this new class. So add the
following line to your
cartridges\andromda-hibernate\src\META-INF\andromda-metafacades.xml
<metafacade
metaobjectClass="org.omg.uml.foundation.core.UmlClass$Impl"
metafacadeClass="org.andromda.cartridges.hibernate.metafacades.HibernateEntityFacadeLogicImpl"
contextRoot="true">
<stereotype>Entity</stereotype>
</metafacade
Now you have to add your new function to the LogicImpls.
So goto
<andromda-src-dir>/cartridges/andromda-hibernate/src/java/org/andromda/cartridges/hibernate/metafacades
There will be a file called HibernateEntityFacade.java with your new
functions. Implement your function here. You have now all the power
that java has and java is much more powerful then velocity.
Recompile the hibernate cartridge:
cd <andromda-src-dir>/cartridges/andromda-hibernate/
maven jar:install
and then try to rebuild your application.
Any ideas are wellcome
Thanks at advance
Regards
Bruno
Greetings Manuel
-------------------------------------------------------
This SF.Net email is sponsored by: YOU BE THE JUDGE. Be one of 170
Project Admins to receive an Apple iPod Mini FREE for your judgement on
who ports your project to Linux PPC the best. Sponsored by IBM.
Deadline: Sept. 13. Go here: http://sf.net/ppc_contest.php
_______________________________________________
Andromda-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/andromda-user
|