Hi Usama,

You can use two separate binding definitions for this purpose. All the 
common stuff can go in one binding, which the other bindings then include:

common-binding.xml:

<binding>
  <mapping name="common"...>
  </mapping>
</binding>

message1-binding.xml:

<binding>
  <include path="common-binding.xml"/>
  <mapping name="message"...>
  </mapping>
</binding>

etc.

  - Dennis

Dennis M. Sosnoski
SOA and Web Services in Java
Training and Consulting
http://www.sosnoski.com - http://www.sosnoski.co.nz
Seattle, WA +1-425-939-0576 - Wellington, NZ +64-4-298-6117



Usama Rashwan wrote:
> if i have two XML files with the same root tag how can i bind them 
> using JIBX
> because mapping element in JIBX doesn't allow to have the same name 
> twice in binding files and will throw exception if i put the name 
> message for two binding classes
>
>
> for example
> XML format 1
> <message>
>                <common>
>                          .................
>               </common>
>                 <service1>
>                  </scrvice1>
> </message>
>
> <message>
>                <common>
>                          .................
>               </common>
>                 <service2>
>                  </scrvice2>
> </message>
>
> ------------------------------------------------------------------------
> Don't get soaked. Take a quick peek at the forecast 
> <http://tools.search.yahoo.com/shortcuts/?fr=oni_on_mail&#news>
> with theYahoo! Search weather shortcut. 
> <http://tools.search.yahoo.com/shortcuts/?fr=oni_on_mail&#news>
> ------------------------------------------------------------------------
>
> -------------------------------------------------------------------------
> Take Surveys. Earn Cash. Influence the Future of IT
> Join SourceForge.net's Techsay panel and you'll get the chance to share your
> opinions on IT & business topics through brief surveys-and earn cash
> http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
> ------------------------------------------------------------------------
>
> _______________________________________________
> jibx-users mailing list
> jibx-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/jibx-users
>   

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
jibx-users mailing list
jibx-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jibx-users

Reply via email to