At 10:16 AM -0500 2/19/02, Anthony W. Marino wrote:
Using SAX "characters()" event handler I get 2 different interpretations of
the expansion of an external file.  This external file is nothing more than a
text file with several lines of text and the first line is an XML comment
line.


At first glance, it looks like both cases are providing you with the exact same data. One breaks it up into a surprisingly large number of parts, but both provide exactly the same information (unless I missed something picky in the white space). In general SAX does not guarantee how many separate characters it will stuff into each call to characters. Your code needs to be written in such a way that it can handle extreme cases like every single character resulting in a separate call to characters().


See http://www.cafeconleche.org/books/xmljava/chapters/ch06s07.html for details
--

+-----------------------+------------------------+-------------------+
| Elliotte Rusty Harold | [EMAIL PROTECTED] | Writer/Programmer |
+-----------------------+------------------------+-------------------+
|          The XML Bible, 2nd Edition (Hungry Minds, 2001)           |
|              http://www.ibiblio.org/xml/books/bible2/              |
|   http://www.amazon.com/exec/obidos/ISBN=0764547607/cafeaulaitA/   |
+----------------------------------+---------------------------------+
|  Read Cafe au Lait for Java News:  http://www.cafeaulait.org/      |
|  Read Cafe con Leche for XML News: http://www.ibiblio.org/xml/     |
+----------------------------------+---------------------------------+

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to