Hi Holger, You'd need to read the DOCTYPE information from the parser yourself before you turn control over to the JiBX unmarshalling. See the "Controlling JiBX with front-end code" example at http://jibx.sourceforge.net/tutorial/binding-custom.html#frontend for an example of how this type of thing is done (in the example it's using an attribute on the root element, but the same sort of principle applies for what you want - create the UnmarshallingContext and use the IXMLReader to check for an item of type DOCDECL, then read the text for that item and process it however you want).
- 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 Holger Schultz wrote: > Hi all, > > I've got a little problem with getting header infos from a XML-file. I read a > lot about writting those Informations from Java with JiBX to XML but I've > found > nothing about reading them. > > I need those infos because of references to external entites which are part of > the DOCTYPE element. Header info looks like this: > > <?xml version="1.0" encoding="iso-8859-1"?> > <!DOCTYPE PROJECT PUBLIC "-//SOMETHING//NEXTTHING//" "myOwn.dtd" > [ > <!NOTATION SGML SYSTEM ""> > <!ENTITY ENT.ID.UDS PUBLIC "-//SOMETHING//NEXTTHING// XML UDS=5FLS//DE" > ".//ANOTHERTHING" NDATA SGML> > ]> > > Is there an easy way to read these infos with JiBX or do I have to use my own > reader? > > Thanks for any help, > Holger > > ------------------------------------------------------------------------- > 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 > > ------------------------------------------------------------------------- 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