W3C

SequenceElementList Example

  <xs:element name="sequenceElementList" type="ex:SequenceElementList"/>

  <xs:complexType name="SequenceElementList">
        <xs:sequence>
          <xs:element name="item" minOccurs="0" maxOccurs="unbounded" type="xs:string"/>
        </xs:sequence>
      </xs:complexType>

The example schema [SequenceElementList.xsd] has been classified as being a Basic XML Schema Patterns for Databinding 1.0 conformant document as it only exhibits the following patterns:

Status Name XPath
basic TargetNamespace .[@targetNamespace]/ (., @targetNamespace)
basic QualifiedLocalElements .[@elementFormDefault = 'qualified']/ (@elementFormDefault)
basic UnqualifiedLocalAttributes .[not(@attributeFormDefault) or @attributeFormDefault = 'unqualified']/ (., @attributeFormDefault)
basic IdentifierName .//.[matches(@name, "^[A-Za-z_]([A-Za-z0-9_]0 31)$")]/ (@name)
basic GlobalElement ./xs:element[@name and @type and contains(@type, ':')]/ (., @name, @type)
basic ElementMinOccurs0MaxOccursUnbounded .//xs:element[@minOccurs = '0' and @maxOccurs = 'unbounded']/ (@minOccurs, @maxOccurs)
basic GlobalComplexType ./xs:complexType[@name]/ (., @name)
basic ComplexTypeSequence .//xs:complexType/xs:sequence/ (., xs:element/(., @name))
basic SequenceElement .//xs:sequence/xs:element/(.)
basic SequenceSingleRepeatedElement .//xs:sequence[count(xs:element) = 1]/xs:element[@maxOccurs = 'unbounded']/ (., @maxOccurs)
basic ElementTypeReference .//xs:element[@name and @type and namespace-uri-from-QName(resolve-QName(@type,.)) != 'http://www.w3.org/2001/XMLSchema' and contains(@type, ':')]/ (., @name, @type)
basic StringElement .//xs:element/@type[resolve-QName(.,..) = xs:QName('xs:string')]

To facilitate testing, the example schema element has been wrapped in the following descriptions:

The following valid instance documents are provided:

Instance Validity
SequenceElementList01 true
SequenceElementList02 true
SequenceElementList03 true

  <ex:sequenceElementList>
        <ex:item>item one</ex:item>
        <ex:item>item two</ex:item>
        <ex:item>item three</ex:item>
        <ex:item>item four</ex:item>
      </ex:sequenceElementList>
  <ex:sequenceElementList>
        <ex:item>item one</ex:item>
      </ex:sequenceElementList>
  <ex:sequenceElementList/>

This document was produced by the W3C XML Schema Patterns for Databinding Working Group. Comments on this document may be sent to the public public-xsd-databinding-comments@w3.org mailing list (public archive).

Generated from examples.xml $Date$