db-jdo-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jörg von Frantzius <joerg.von.frantz...@artnology.com>
Subject Re: Dependent and element-dependent
Date Fri, 27 Jan 2006 15:30:51 GMT
Please see my comments below on how JPOX will treat dependent vs. 
element-dependent on collection fields. Please reply if you have objections!

Craig L Russell schrieb:
> Hi Jörg,
>
> On Nov 3, 2005, at 1:49 AM, Jörg von Frantzius wrote:
>
>> Hello,
>>
>> the specification currently is somewhat confusing where it defines 
>> the meta-data attributes "dependent" and "element-dependent". 
>> Concerning "dependent" it says:
>>
>>    "The dependent attribute indicates that the field contains a
>>    reference that is to be deleted
>
> The reference is the object that is referenced by the field. I'll try 
> to clarify this in the spec.
>
>>    from the datastore if the referring instance in which the field is
>>    declared is deleted, or if the
>>    referring field is nullified."
>>
>> Now does that mean that really the *reference* is to be deleted 
>> (which seems kinda natural to me), or rather the object being 
>> referred to? Probably the latter?
>
> Yes.
>>
>> For collection fields, there is the additional "dependent-element" 
>> attribute of the "collection" tag. Wouldn't it be enough to have 
>> "dependent" on the field level?
>
> We try to make the field metadata refer to behavior of the field 
> itself, and put the behavior of multi-valued field types (array, 
> collection, map) in separate metadata to better match the semantics of 
> Collection versus Element.
>
> We could make it illegal to specify dependent on field types of array, 
> collection, and map...
>
>> Or what does it mean if the user specifies 'dependent="false"' with 
>> nested 'element-dependent="true"', or vice-versa?
>
> See above.
JPOX will ignore any "dependent" attribute setting on Collection fields, 
so only the "element-dependent" attribute will be of meaning for 
Collection fields.
>
> Experts, any opinion on this subject?
>
> Craig
>>
>> Thanks for any explanations,
>> Jörg
>>
>> --__________________________________________________________
>> Dipl.-Inf. Jörg von Frantzius  |            artnology GmbH
>>                               |                Milastr. 4
>> Tel +49 (0)30 4435 099 26      |              10437 Berlin
>> Fax +49 (0)30 4435 099 99      |  http://www.artnology.com
>> _______________________________|__________________________
>>
>
> Craig Russell
> Architect, Sun Java Enterprise System http://java.sun.com/products/jdo
> 408 276-5638 mailto:Craig.Russell@sun.com
> P.S. A good JDO? O, Gasp!
>
>


-- 
__________________________________________________________
Dipl.-Inf. Jörg von Frantzius  |            artnology GmbH
                               |                Milastr. 4
Tel +49 (0)30 4435 099 26      |              10437 Berlin
Fax +49 (0)30 4435 099 99      |  http://www.artnology.com
_______________________________|__________________________


Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message