Skip to main content



      Home
Home » Modeling » EMF » [CDO] Dealing with extended meta model
[CDO] Dealing with extended meta model [message #1006478] Thu, 31 January 2013 07:52 Go to next message
Eclipse UserFriend
EMF since some time supports code generation of derived features, invariants etc...
In my original model, I defined these things, starting from .XSD. Here is an example:

<!-- Derived attributes -->
<xs:attribute ecore:derived="true" ecore:transient="true"
ecore:volatile="true" name="Count" type="xs:int">
<xs:annotation>
<xs:documentation>OCL derived feature: Count all equipments.
</xs:documentation>
<xs:appinfo ecore:key="derivation"
source="http://www.eclipse.org/emf/2002/Ecore/OCL">self.equipments-&gt;size()
</xs:appinfo>
</xs:annotation>
</xs:attribute>


Now I wonder, how does CDO deal with this? I see in the generated Class for this attribute delegates
to eGet(). Does the eStore pass it on to the OCL Query handler? How is this supposed to work?

thank you
Christophe





Re: [CDO] Dealing with extended meta model [message #1006497 is a reply to message #1006478] Thu, 31 January 2013 09:00 Go to previous message
Eclipse UserFriend
Am 31.01.2013 13:52, schrieb Christophe Bouhier:
> EMF since some time supports code generation of derived features, invariants etc... In my original model, I defined
> these things, starting from .XSD. Here is an example:
> <!-- Derived attributes -->
> <xs:attribute ecore:derived="true" ecore:transient="true"
> ecore:volatile="true" name="Count" type="xs:int">
> <xs:annotation>
> <xs:documentation>OCL derived feature: Count all equipments.
> </xs:documentation>
> <xs:appinfo ecore:key="derivation"
> source="http://www.eclipse.org/emf/2002/Ecore/OCL">self.equipments->size()
> </xs:appinfo>
> </xs:annotation>
> </xs:attribute>
>
>
> Now I wonder, how does CDO deal with this? I see in the generated Class for this attribute delegates
> to eGet(). Does the eStore pass it on to the OCL Query handler? How is this supposed to work?
I've never used this functionality myself, but I suspect that annotated OCL expressions get evaluated on the client side.

Cheers
/Eike

----
http://www.esc-net.de
http://thegordian.blogspot.com
http://twitter.com/eikestepper
Previous Topic:[CDO] Setting Security : Authentication & Access control
Next Topic:[CDO] CDO/GMF compatibility
Goto Forum:
  


Current Time: Wed Jul 23 06:38:45 EDT 2025

Powered by FUDForum. Page generated in 0.03164 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top