[xml] xmlTextReaderSetSchema and dynamic setting of the schema
- From: "David D. Hagood" <wowbagger sktc net>
- To: xml gnome org
- Subject: [xml] xmlTextReaderSetSchema and dynamic setting of the schema
- Date: Fri, 09 Feb 2007 10:29:39 -0600
I'd like to check my understanding:
According to the documentation, if you want to have an xmlTextReader do
schema validation, you have to set the schema before the first read call
on the text reader.
HOWEVER, if you are trying to make a reader routine which can handle
multiple document types, you don't know the doc type until you've read
the DOCTYPE element, which you don't know until you've done a Read on
the Reader - which makes it too late to activate a schema.
So as I read it, there is no way to read the first 2 lines of a stream
(which may not be seekable), deduce the schema needed from the DOCTYPE
record, then activate the appropriate schema.
Is this a correct assessment?
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]