W3C home > Mailing lists > Public > xmlschema-dev@w3.org > June 2002

Re: Recursion and validation

From: Ian Stokes-Rees <ijs@decisionsoft.com>
Date: Thu, 27 Jun 2002 09:39:34 +0100
To: James Kavanagh <jkavanagh@adeptra.com>
Cc: xmlschema-dev@w3.org
Message-ID: <20020627093930.A21313@decisionsoft.com>

The only thing I could suggest is that "patternsType" contains something
of type "integerType", which means you could have a structure which
looked like:

<integer>
  <patterns>
    <integer>
      <patterns>
        <integer>
          ...

(if "integer" was a child of "patterns").  What I do not know is whether
or not the XSDL spec allows this, since "patterns" is a choice inside
"integerType", meaning it may not exist.  And if "patternsType" does not
contain something of "integerType" then I have no idea what the problem
might be.

Ian.

On Wed, Jun 26, 2002 at 11:22:48AM -0400, James Kavanagh wrote:
> Hi,
> 
> I'm using XML spy as an authoring tool for my XML schema and when I
> create the schema and validate it therein there are no problems.
> However, when I attempt to validate against that schema using the Xerces
> 1.4.4 parser I get the following error:
> 
> Schema error: Anonymous complexType: ct-props-correct.3:  Recursive type
> definition.
> 
> The actual section of the schema this message is reported as referring
> to:
> 
<xs:complexType name='integerType'>
  <xs:sequence>
    <xs:element type='xs:integer' name='default' minOccurs='0' />
    <xs:choice minOccurs='0'>
      <xs:element maxOccurs='unbounded' name='range'>
        <xs:complexType>
          <xs:sequence>
            <xs:element type='xs:integer' name='min' />
            <xs:element type='xs:integer' name='max' />
          </xs:sequence>
        </xs:complexType>
      </xs:element>
      <xs:element name='enum'>
        <xs:complexType>
          <xs:sequence>
            <xs:element maxOccurs='unbounded' type='xs:integer' name='item' />
          </xs:sequence>
        </xs:complexType>
      </xs:element>
      <xs:element type='patternsType' name='patterns' />
    </xs:choice>
  </xs:sequence>
</xs:complexType>
> 
> Can anyone help on this?
> 
> 

-- 
Ian Stokes-Rees, Client Services      DecisionSoft Ltd.
Telephone: +44-1865-203192            http://www.decisionsoft.com
Received on Thursday, 27 June 2002 04:39:37 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 11 January 2011 00:14:31 GMT