Hi Ronald, I removed this restriction in the current 1.1.3 release code (though I never did update the web site to match). You can do exactly what you want, have a binding with only <format> definitions which you then <include> into other bindings.
- 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 Ronald Johnson wrote: > Hi, > > I followed Stephans comments on how to format Date, and it works fine > (thanks!). > > Since the formatting are general (and we will probably re-use them for > many bindings), I wanted to put them in a separate file that is > included in my binding files. > > I tried this: > > global_formats.xml: > <binding> > <format label="Date_dd.mm.yyyy" type="java.util.Date" > > serializer="de.mecom.dpaplattform.util.JibxSerializer.serializeGermanDate" > > deserializer="de.mecom.dpaplattform.util.JibxSerializer.deserializeGermanDate" > /> > </binding> > > and include it in my binding files (with normal include). > However, jibx complains > org.jibx.runtime.JiBXException: One or more <mapping> elements must be > defined in <binding> > > I am not sure how can I remedy that, since the mapping tag demands a > class name.... > > What is the correct way to put formats in a separate file? > How do you guys do this (and similar behaviour) > > ------------------------------------------------------------------------- > 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 > [email protected] > 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 [email protected] https://lists.sourceforge.net/lists/listinfo/jibx-users
