OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

 


 

   How to create "strict" flag for schema?

[ Lists Home | Date Index | Thread Index ]
  • To: xml-dev@lists.xml.org
  • Subject: How to create "strict" flag for schema?
  • From: David Nedrow <listbox@nedron.net>
  • Date: Thu, 01 Dec 2005 15:21:34 -0500
  • User-agent: Thunderbird 1.5 (X11/20051025)

I'd like to be able to modify my schema to allow for "strict" usage. 
Eg., in the simplified schema portion below, I've define <hextype/>. As 
it stands, I'm only accepting [0-9A-F] which I consider a "strict" form 
of hexadecimal entry. I would also like to allow [0-9a-fA-F] as a 
"loose" form.

Basically, my question is, how can I modify my schema and the example 
element below to allow the user to create a "strict" ipdt markup. Note 
that ipdt is actually just a number of base types that are used in 
another schema. So, in the other schema (ipxml) I need (I assume) a 
global flag for strict, then proper processing in <hextype/> to handle 
the global strict flag.

<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"; 
targetNamespace="ipdt" xmlns="ipdt" elementFormDefault="qualified">
    <xs:simpleType name="hextype">
        <xs:restriction base="stringtype">
            <xs:pattern value="[0-9A-F]"/>
        </xs:restriction>
    </xs:simpleType>
</xs:schema>





 

News | XML in Industry | Calendar | XML Registry
Marketplace | Resources | MyXML.org | Sponsors | Privacy Statement

Copyright 2001 XML.org. This site is hosted by OASIS