Vladimir, I think you might be better off posting this request for help to the Xerces dev mailing list (xerces-j-dev@xml.apache.org). The cvs mailing list is pretty much reserved for check-in notices -- plus, I think the correct cvs address is [EMAIL PROTECTED], so you probably got an error when you sent this off. I'm not sure why you copied the LotusXSL team on this email since it seems as though you have XML-specific questions, but if you think we can be of some help, then please let us know.
Emily Farmer LotusXSL_Team "Vladimir Savtchenko" To: <xerces-cvs@xml.apache.org> <[EMAIL PROTECTED] cc: (bcc: Lotusxsl_Team) t> Subject: limitations of Xerces-J 1.0.3 05/14/00 03:21 AM Please respond to xerces-dev Hi! Im using the Xerces-J 1.0.3 parser, to parse XML files, save their parsed representation, and than when needed, recreate the XML-file from what I've parsed. I found that the parser has several limitations. Consider the following simple XML (also attached to the mail): <?xml version="1.0" encoding="utf-8" standalone="yes"?> <!DOCTYPE D [ <!ELEMENT D ( A ) > <!ELEMENT A (#PCDATA)> <!ENTITY F "ent_f"> <!ENTITY G "end_g"> <!ENTITY SP " "> <!ATTLIST D a1 CDATA #IMPLIED a2 CDATA #IMPLIED> <!ATTLIST A f1 CDATA #FIXED "fix1"> ] > <D a="&F;" a2="&G;"> <A> argument "f1" is not given </A> <A f1 = "fix1"> arg "f1" is given with value like the fixed </A> <A> and this is "&SP;" entity </A> </D> First: There is no way to get the values of 'version', 'encoding', 'standalone' in the prolog. What I've done was to extend SAXParser, and write my own 'startDocument' function which saves the values I need. Second: Concider the attributes of the element "D"... when the parser parses them he tells me that there is an enitty before even told me that a new element has begun... and then when he calls 'startElement(...)' and tells me the attribute values, they are already resolved and there is no way to know what they were before they got resolved Third: In the 3 elements of type A, there is always one argument .. f1='fix1' .. but i cannot know if this is the default value.. or is it the value the user set.. which is the same as the default Fourth: When there is an entity such as the &SP; in the example the parser just parses it and replaces it with space, but what if I dont want it replaced? I hope you'll understand my needs and tell me if there is a way to do this things, or are these parser limitations.