[xml] xs:normalizedString and xs:token
- From: "Hakan Yüksel" <h yueksel gmx de>
- To: xml gnome org
- Subject: [xml] xs:normalizedString and xs:token
- Date: Tue, 02 Jun 2009 16:01:40 +0200
Hi,
I have a scheme with:
<xs:element name="a" type="xs:token"/>
<xs:element name="a2" type="xs:normalizedString"/>
and a corresponding xml document:
<?xml version="1.0" encoding="UTF-8"?>
<root>
<a>
some
thing
</a>
<a2>
some
thing
</a2>
</root>
I've assumed that after validation with xmlSchemaValidateDoc the output of my xmlDocPtr is as:
<?xml version="1.0" encoding="UTF-8"?>
<root>
<a>some thing</a>
<a2> some thing</a2>
</root>
My assumption is based on the schema tutorial of the W3 consortium
(http://www.w3schools.com/schema/schema_dtypes_string.asp).
But it does not work this way. How can I achieve this behavior? I've tried to use xmlSchemaCheckFacet and
xmlSchemaValidateFacet but it also doesn't work and I'm not sure if I use it correctly. Can I find sample
code somewhere how xmlSchemaValidateFacet works? I've assumed to find something in xmllint.c but it wasn't
the case.
Best regards, Hakan
--
GMX FreeDSL mit DSL 6.000 Flatrate und Telefonanschluss nur 17,95 Euro/mtl.!
http://dslspecial.gmx.de/freedsl-aktionspreis/?ac=OM.AD.PD003K11308T4569a
[Date Prev][
Date Next] [Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]