Hi,


playing around with AndroMDA ( for some time on  a learning project i ran into 
the following problem when trying to define a more sophisticated query in OCL:



Method

findNamedInstances(names:Collection) : Collection



OCL

context Grape::findNamedInstances( names:Collection(String) ) : 
Collection(Grape) body findNamedInstancesBody: allinstances()->select( grape | 
names->exist( name | name=grape.name ) )



Generated XDoclet Tag

@ejb.finder signature="java.util.Collection 
findNamedInstances(java.util.Collection names)"

            query="WHERE name = grape.name"



Generated EJBQL

         <query>

            <query-method>

               <method-name>findNamedInstances</method-name>

               <method-params>

                  <method-param>java.util.Collection</method-param>

               </method-params>

            </query-method>

            <ejb-ql><![CDATA[WHERE name = grape.name]]></ejb-ql>

         </query>



I'm no EJB expert but the  generated EJBQL (boldfaced) doesn't look like 
something that could work.

The intended behaviour is to match all 'Grape' instances that are contained in 
the list of 'names' given as the parameter of the method findNamedInstances.



The AndroMDA Version I'm using:

   INFO  [AndroMDA] A n d r o M D A  -  3.0-RC1
--
--

  JL
_________________________________________________________
Reply to the post : http://galaxy.andromda.org/forum/viewtopic.php?p=2233#2233
Posting to http://forum.andromda.org/ is preferred over posting to the mailing 
list!


-------------------------------------------------------
This SF.Net email is sponsored by the 'Do More With Dual!' webinar happening
July 14 at 8am PDT/11am EDT. We invite you to explore the latest in dual
core and dual graphics technology at this free one hour event hosted by HP, 
AMD, and NVIDIA.  To register visit http://www.hp.com/go/dualwebinar
_______________________________________________
Andromda-user mailing list
Andromda-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/andromda-user

Reply via email to