[XML-SIG] Determining output encoding of a SAX parser

Lars Marius Garshol larsga@garshol.priv.no
25 Oct 2000 11:39:18 +0200


* A. M. Kuchling
|
| Is there any way to determine the encoding of the output from a SAX1
| parser driver?

No, there is not.  You simply get 8-bit strings with no semantics
attached.

| Given that SAX2 does seem to support this with
| XMLReader.{get,set}Encoding(),

There is no XMLReader.{get,set}Encoding() in Python or Java SAX 2.0.
There are methods with these names on InputSource, but that is
something completely different.

| is this worth fixing in SAX1?  

No, I don't think it is.  SAX 1.0 is obsolete now, and we should all
move on to SAX 2.0.  In SAX 2.0, the goal is to have all drivers (or
at least as close to all as possible) emit Unicode strings.

--Lars M.