RE: [xml] libxml2 support for xml schema data types


-----Original Message-----
From: xml-bounces gnome org [mailto:xml-bounces gnome org] On 
Behalf Of Andric, Milan
I'm wondering if libxml2 supports XML Schema data types?
Something like:
<?xml version="1.0"?>
<weather xmlns="x-schema:weatherSchema.xml">
<Schema xmlns="urn:schemas-microsoft-com:xml-data" 
  <ElementType name="date" content="textOnly" dt:type="date"/>
  <ElementType name="degrees" content="textOnly" dt:type="float"/>
  <ElementType name="weather" content="eltOnly">
    <element type="date"/>
    <element type="degrees"/>
Can libxml2 figure out type of data in <date> and <degrees>?
I'd appreciate any help on this. 
Please reply directly to: andricm @ (in addition 
to mailing list)

I'm not 100% sure what you mean by "figure out type of data". If you
are asking if the W3C XML Schema processor of Libxml2 is able to
understand (and validate against) W3C XML Schema datatypes, then yes.

I assume you are aware that the schema used in your example is not
a W3C XML Schema, plus the datatypes are not W3C XML Schema datatypes.
This is a MS propriatary schema ("urn:schemas-microsoft-com:xml-data")
using MS propriatary datatypes in the namespace
"urn:schemas-microsoft-com:datatypes". Maybe there are tools out there,
which can transform such MS schemata to W3C XML Schemata.



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]