[xsd-users] xsd:any in parser
Jiri Poledna
jiripoledna at seznam.cz
Mon May 21 10:27:25 EDT 2007
Hi
I need some help with XSD parser, I have following xsd file
<?xml version="1.0" encoding="UTF-8"?>
<xsd:schema xmlns:xsd=[1]"http://www.w3.org/2001/XMLSchema">
<xsd:element name="Reviewer">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="Name" type="xsd:string">
</xsd:element>
</xsd:sequence>
</xsd:complexType>
</xsd:element>
<xsd:element name="root">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="Title">
<xsd:complexType>
<xsd:attribute name="SchemaVersion" type="xsd:string"
default="3.0.3" />
<xsd:attribute name="ID" type="xsd:string" use="required"
/>
</xsd:complexType>
</xsd:element>
<xsd:any namespace="##any" processContents="skip" />
</xsd:sequence>
</xsd:complexType>
</xsd:element>
</xsd:schema>
for xml
<?xml version="1.0"?>
<root xmlns:xsi=[2]"http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="D:\users\jp\VStudio.NET\book.xsd">
<Title ID="prvni"></Title>
<Reviewer Name="Nemo"/>
</root>
I'm using xsd.exe utility to generate the hxx and txx, I obtained
parserhooks to Title element, but I do not reach Reviewer element. I
saw
[3]http://www.codesynthesis.com/pipermail/xsd-announcements/2007/00002
0.html
this line
* Proper handling of an xsd:any nested content. Nested elements,
attributes, and text are reported via _any_* hooks of the current
parser.
but I do not see _any_* hook, can you help me how to handle xsd:any attribute i
n parser?
Thanks
Jiri
References
1. http://www.w3.org/2001/XMLSchema
2. http://www.w3.org/2001/XMLSchema-instance
3. http://www.codesynthesis.com/pipermail/xsd-announcements/2007/000020.html
More information about the xsd-users
mailing list