You'd have to write your own custom (un)marshaller to do this. Wouldn't
take much code but you'd have to surmount the learning curve.

Another slightly less elegant option is to declare a private bean property
of a different type (a bean type with "month" and "year" properties) that
just reflects the original date value. Then map the private property with
JiBX instead of the original property.

-Archie

On Mon, May 13, 2013 at 1:14 PM, John Smith <java.dev....@gmail.com> wrote:

> Using the latest JiBX.
>
> Is it possible to merge two xml fields into class parameter?
>
> Say I have thise XML fragement
>
> <ExpiryDate>
>      <Month>12</Month>
>      <Year>2014</Year>
> </ExpiryDate>
>
>
> My model (POJO)
>
> Contains 1 String field called expiryDate and the format also must be
> YYYYMM
>
>
> ------------------------------------------------------------------------------
> AlienVault Unified Security Management (USM) platform delivers complete
> security visibility with the essential security capabilities. Easily and
> efficiently configure, manage, and operate all of your security controls
> from a single console and one unified framework. Download a free trial.
> http://p.sf.net/sfu/alienvault_d2d
> _______________________________________________
> jibx-users mailing list
> jibx-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/jibx-users
>
>


-- 
Archie L. Cobbs
------------------------------------------------------------------------------
AlienVault Unified Security Management (USM) platform delivers complete
security visibility with the essential security capabilities. Easily and
efficiently configure, manage, and operate all of your security controls
from a single console and one unified framework. Download a free trial.
http://p.sf.net/sfu/alienvault_d2d
_______________________________________________
jibx-users mailing list
jibx-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jibx-users

Reply via email to