From: Tatu S. <cow...@ya...> - 2006-11-18 20:36:03
|
--- Paul Tomsic <pt...@gm...> wrote: > i need a way, if given an XML document, to determine > if a node was > marked as mixed=true in the schema. if it was, then > return it's > children nodes as text. is this possible within > vtd? You'd need to check the Schema. That's something VTD-XML is not designed to deal with. You could of course parse schema with it, but that just gives you InfoSet... you really need something more to give more convenient access to schema. Now, if you are thinking of heuristically checking if there happens to be any mixed content, that is bit harder... since white space may or may not count, depending on schema (or dtd, rng). Besides, VTD-XML implicitly ignores some of the white space -- it'll still be in source document contents, there just won't be matching event (if I understand things correctly). Most of the time this works out ok, but may be surprising if one is used to other APIs which expose the full infoset (white space still is part of info set, even if most of the time is not used for anything). Once you have that info (whether mixed content is allowed), you can use VTD-XML for accessing things. -+ Tatu +- ____________________________________________________________________________________ Sponsored Link Online degrees - find the right program to advance your career. Www.nextag.com |