Hi, I have XML that looks like: 
<FieldValue>
  <NameValuePair type="CodeType" ...>
  ...
</FieldValue>

In Java I have an abstract FieldValue base class and subclasses FieldCode and 
FieldCodeType.

If during unmarshalling, type="CodeType" I want to unmarshal the FieldValue 
element into an instance of FieldCodeType and if 
type equals anything else I want to unmarshal into an instance of FieldCode.  
During marshalling I want both subclasses to marshal
to a FieldValue element.  The marshalling part is easy (just define mappings 
for the subclasses), but I assume I will
need to use a custom unmarshaller, but can't figure out exactly how to make 
this work or if this is even possible.
Any help would be much appreciated.  Thanks, - Jon
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
jibx-users mailing list
jibx-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jibx-users

Reply via email to