Re: [Fwd: Re: [xml] load() and includes]
- From: Daniel Veillard <veillard redhat com>
- To: Trevor Lowing <Trevor Lowing XML Lowing org>
- Cc: xml gnome org
- Subject: Re: [Fwd: Re: [xml] load() and includes]
- Date: Fri, 8 Jul 2005 04:13:35 -0400
On Sun, Jul 10, 2005 at 03:32:03AM -0400, Trevor Lowing wrote:
since the XML Schemas implementation does it, and the code is there,
just read it !
Daniel
Sorry to be so thick-skulled but, does the Schemas implementation load
all the includes into one big DOM Document? If so, is there any way to
access the DOM document and perform DOM operations? Or, am I stuck
trying to do weird stuff like you mentioned in the thread titled
"Assembling xml documents from multiple wsdl files"? Could you point me
to an example showing use of the Schema API close to what I need? I'm
I don't know what you need to do. You want to implement xsd:include semantic.
That code is done internally in the schemas module. There is no possible
manual intervention on this as the behaviour is defined by the Schemas
spec.
sifting through the xmlschemas.c code but I am having a tough time
tracing things.
yes it's big complex, and that's one of the reasons why opening up the
internal processing is a red herring.
Load Schema(s) into a DOM document tree
that you can do with the normal APIs except it's not strictly speaking DOM
it is libxml2 tree APIs
(including includes)
you will have to scan the tree to spot the include and load them yourself.
This requires way less work than trying to open and maintain over libxml2
software lifetime the APIs to tweaks the schemas internals.
Validate Schema as a valid schema
Once you have a tree use the existing APIs.
Manipulate DOM document
libxml2 tree API
save DOM document to new file
libxml2 tree API
Daniel
--
Daniel Veillard | Red Hat Desktop team http://redhat.com/
veillard redhat com | libxml GNOME XML XSLT toolkit http://xmlsoft.org/
http://veillard.com/ | Rpmfind RPM search engine http://rpmfind.net/
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]