I would like to try using jibx on a new project.  I have worked the
examples and was wondering if anyone could point me toward a solution to
the following problem.  Can I do this without custom code?

 

I was looking for direction on how to create a mapping that would handle
creation of a specific concrete class based upon either an element or
attribute within the XML.

 

For example my XML for Widget might be:

 

<root>

      <widget>

         <type>CAR</type>

         <name1>benz</name1>

    <name2>rudy</name2>

<name3>good</name3>

      </widget>

         <type>TRUCK</type>

         <name1>chevy</name1>

    <name2>silverado</name2>

<name3>xl</name3>

      </widget>

</root>

 

The concrete classes being

 

public class Auto ...

public class Truck ...

 

And I would like to map widget.type=CAR to the concrete Auto class.
And, widget.type=TRUCK to the Truck class.

 

 

This communication and attachments is intended only for the use of the
addressee[s] named herein and may contain legally privileged and/or
confidential information. If you are not the intended recipient of this
e-mail, you are hereby notified that any dissemination, distribution or
copying of this e-mail, and any attachments thereto, is strictly
prohibited. If you have received this e-mail in error, please notify me
via return e-mail or via telephone and permanently delete the original
and any copy of any e-mail and any printout thereof.

Eugene Von Haden 
Midwest Development Center Information Technology 
Wausau Insurance 
Liberty Mutual Insurance Group                                     
email:[EMAIL PROTECTED] 
phone:(715)843-2942 
sdn: 08-206-2942  

 

<<image001.gif>>

-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
jibx-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jibx-users

Reply via email to