Hi Darren,

have you already read http://www.castor.org/how-to-map-a-list-at-root.html ?

Regards
Ralf

Darren Davison schrieb:
> hi,
>
> we're trying to implement castor and remove 2 or 3 various other
> marshalling/unmarshalling technologies in a project.  One need we have
> is to unmarshall a collection of 'content' objects - the root object
> being of type TreeSet<Content>.
>
> public class Content {
>   public static enum Type {file, folder};
>   Type type;
>   String name;
>   String desc;
>   String uri;
>   // plus getters/setters
> }
>
> <!-- current example of the XML to transform -->
> <content-set>
>   <file name="foo.xml" desc="description" uri="file://blah/foo.xml"/>
>   <folder name="bar" desc="desc of bar" uri="./bar"/>
> </content-set>
>
> I have no idea if this is possible with castor, and I'm struggling to
> find good examples of anything similar either.  Could anyone point me at
> a reasonable doc/example?  Or tell me if what I'm doing is
> impossible/close-to-impossible?
>
> We can change the XML schema if it would help, but the TreeSet<Content>
> would be harder to change.
>
> Many thanks,
>   
-- 

Syscon Ingenieurbüro für Meß- und Datentechnik GmbH
Ralf Joachim
Raiffeisenstraße 11
72127 Kusterdingen
Germany

Tel.   +49 7071 3690 52
Mobil: +49 173 9630135
Fax    +49 7071 3690 98

Internet: www.syscon.eu
E-Mail: [email protected]

Sitz der Gesellschaft: D-72127 Kusterdingen
Registereintrag: Amtsgericht Stuttgart, HRB 382295
Geschäftsleitung: Jens Joachim, Ralf Joachim




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

    http://xircles.codehaus.org/manage_email


Reply via email to