Interesting. Given that attributes only accept simple types as their respective 
types, this doe not surprise me (well, I actually expected this). But that a 
collection of enum typed elements should work as well. If you feel like it, I'd 
appreciate if you opened a new Jira issue at 

http://jira.codehaus.org/browse/CASTOR

and attached a fully working (albeit minimal) JUnit test case, incl. any 
required files to run this.

Werner Guttmann
> -----Ursprüngliche Nachricht-----
> Von: Kathrin Baumgartner [mailto:[EMAIL PROTECTED]
> Gesendet: Dienstag, 17. April 2007 14:10
> An: [email protected]
> Betreff: Re: [castor-user] [XML] mapping a collection of type safe enums
> 
> Thanks for you replay.
> I discovered that when I replace node="element" by "attribute" it works.
> So
> I am fine for now.
> 
> Kathrin
> 
> 
> 
> 
> >From: Werner Guttmann <[EMAIL PROTECTED]>
> >Reply-To: [email protected]
> >To: [email protected]
> >Subject: Re: [castor-user] [XML] mapping a collection of type safe enums
> >Date: Mon, 16 Apr 2007 19:37:36 +0200
> >
> >Kathrin,
> >
> >that should be possible out of the box. Can you provide us with small
> >fragments of your mapping file and/or Java classes to give us more
> >details ?
> >
> >Werner
> >
> >Kathrin Baumgartner wrote:
> > > Hi,
> > >
> > > I was wondering if it`s possible in castor 1.1 to map a set of type
> safe
> > > enums.
> > > When I try it with a mapping like
> > >
> > > <class ..>
> > > ...
> > > <field name="myEnum"
> > >      type="somepackage.MyEnum"
> > >      collection="set">
> > >      <bind-xml name="myEnum" node="element" />
> > >    </field>
> > > </class>
> > >
> > > my xml output does not contain any value for myEnum.
> > >
> > > I saw a posting, where sombody resolved that problem by implementing a
> > > custom field handler, but that was some time ago. Is that still how it
> > > is done, or is there an easier way now?
> > >
> > > Thanks,
> > > Kathrin
> > >
> > > _________________________________________________________________
> > > Die neue MSN Suche Toolbar mit Windows-Desktopsuche. Suchen Sie
> > > gleichzeitig im Web, Ihren E-Mails und auf Ihrem PC! Jetzt neu!
> > > http://desktop.msn.de/ Jetzt gratis downloaden!
> > >
> > >
> > > ---------------------------------------------------------------------
> > > To unsubscribe from this list please visit:
> > >
> > >    http://xircles.codehaus.org/manage_email
> > >
> >
> >
> >---------------------------------------------------------------------
> >To unsubscribe from this list please visit:
> >
> >     http://xircles.codehaus.org/manage_email
> >
> 
> _________________________________________________________________
> Sie suchen E-Mails, Dokumente oder Fotos? Die neue MSN Suche Toolbar mit
> Windows-Desktopsuche liefert in sekundenschnelle Ergebnisse. Jetzt neu!
> http://desktop.msn.de/ Jetzt gratis downloaden!
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe from this list please visit:
> 
>     http://xircles.codehaus.org/manage_email


---------------------------------------------------------------------
To unsubscribe from this list please visit:

    http://xircles.codehaus.org/manage_email

Reply via email to