Hi,

I need some help on binding .


For a structure like this


<?xml version="1.0" encoding="UTF-8"?>

<SettlementDate>

     <relativeDate>

           <periodMultiplier>MULTIPLIER</periodMultiplier>

           <period>PERIOD</period>

           <dayType>DAY-TYPE</dayType>

           <businessDayConvention>CONVENTION</businessDayConvention>

           <businessCenter>BUSINESS-CENTER</businessCenter>

           <dateRelativeTo href="">
     </relativeDate>

</SettlementDate>



i am creating the binding like this


<?xml version="1.0" encoding="UTF-8"?>

<binding>

       <mapping name="SettlementDate" class="SettlementDate">

               <structure field="relativeDate"/>

       </mapping>

       <mapping name="relativeDate" class="RelativeDate">

               <value name="periodMultiplier" field="periodMultiplier"/>

               <value name="period" field="period"/>        

               <value name="dayType" field="dayType"/>

               <value name="businessDayConvention" field="businessDayConvention"/>                

               <value name="businessCenter" field="businessCenter"/>                        

               <structure value-style="attribute" name="dateRelativeTo">

                       <value style="attribute" name="href" field="dateRelativeTo"/>                        

               </structure>

       </mapping>

</binding>



My question : Settlement Date is an xml element that contains an element called relativeDate.

Is there any way of binding which will help me avoid creating a class called SettlementDate which is a very trivial class like(refer the markup in bold)



public class SettlementDate {
       private RelativeDate relativeDate;


       //setters and getters follow

}




Regards,

Chetan

_______________________________________________
jibx-users mailing list
jibx-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jibx-users

Reply via email to