jackrabbit-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Boni Gopalan \(BioImagene\)" <Bon...@bioimagene.com>
Subject RE: OCM:Collection Element Node Names
Date Wed, 24 Sep 2008 07:41:19 GMT
I need to have this feature through XML mapping file.  If you can
outline the approach I could fix and provide a patch.

-----Original Message-----
From: Christophe Lombart [mailto:christophe.lombart@gmail.com] 
Sent: 24 September 2008 10:57
To: users@jackrabbit.apache.org
Subject: Re: OCM:Collection Element Node Names

This is not yet possible with the XML file mapping.
With tha OCM annotation, you can use jcrElementName on @Collection. It
should not be difficult to add it in the XML mapping file definition.

Christophe


On Wed, Sep 24, 2008 at 06:31, Boni Gopalan (BioImagene) <
Boni.G@bioimagene.com> wrote:

> I have a Bean in the following structure :
>
>
>
> Class Bar{
>
>            List<Foo> fooList;
>
> }
>
>
>
> Class Foo{
>
>            String name;
>
> }
>
>
>
> This structure is mapped with the following mapping file :
>
>
>
>            <class-descriptor className="Bar"
>
>                         jcrType="nt:unstructured">
>
>            <collection-descriptor fieldName="fooList"
jcrName="fooList"
> proxy="false"
>
>        elementClassName="Foo" jcrSameNameSiblings="false"/>
>
>            </class-descriptor>
>
>
>
>            <class-descriptor className="Foo"
>
>                         jcrType="nt:unstructured">
>
>                        <field-descriptor fieldName="name"
> jcrName="name"/>
>
>            </class-descriptor>
>
>
>
> When the data is saved the ensueing node structure is  like :
>
>
>
>       Bar
>
>          |___fooList
>
>                        |___collection-element
>
>                        |___collection-element
>
>
>
>
>
> My Question is how can I specify a particular node name for
> 'collection-element' ?  Is there an attribute in the mapping file
> (possibly for collection-descriptor) to specify the name of each
> element?
>
>
>
> Thanks
>
>
>
> Boni Gopalan
> Manager Engineering
> BioImagene, Pune
>
> +91-206-609-6579(O)
> +91-992-369-9356(C)
>
>
>
>

Mime
View raw message