E rcase-RecurseLax.1 Group's range, (1,unbounded), ...
This should cover W3C XML Schema, Relax NG and DTD related problems.
-
- Posts: 37
- Joined: Sun Feb 12, 2006 10:34 pm
E rcase-RecurseLax.1 Group's range, (1,unbounded), ...
This is my schema:
<?xml version="1.0" encoding="UTF-8"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified" targetNamespace="http://www.ubs.com/namespace/wbml-render" xmlns="http://www.ubs.com/namespace/wbml-render" xmlns:wbr="http://www.ubs.com/namespace/wbml-render">
<xs:element name="a" type="xs:string"/>
<xs:element name="a1" type="xs:string"/>
<xs:element name="a2" type="xs:string"/>
<xs:element name="a3" type="xs:string"/>
<xs:element name="b" type="xs:integer"/>
<xs:group name="a-Group">
<xs:choice>
<xs:element ref="a1"/>
<xs:element ref="a2"/>
<xs:element ref="a3"/>
</xs:choice>
</xs:group>
<xs:complexType name="groupBaseType">
<xs:choice>
<xs:group ref="a-Group" maxOccurs="unbounded"/>
<xs:element ref="b"/>
</xs:choice>
</xs:complexType>
<xs:complexType name="groupRestrictedType">
<xs:complexContent>
<xs:restriction base="groupBaseType">
<xs:choice>
<xs:group ref="a-Group" maxOccurs="unbounded"/>
</xs:choice>
</xs:restriction>
</xs:complexContent>
</xs:complexType>
<xs:complexType name="baseType">
<xs:choice>
<xs:element ref="a" maxOccurs="unbounded"/>
<xs:element ref="b"/>
</xs:choice>
</xs:complexType>
<xs:complexType name="restrictedType">
<xs:complexContent>
<xs:restriction base="baseType">
<xs:choice>
<xs:element ref="a" maxOccurs="unbounded"/>
</xs:choice>
</xs:restriction>
</xs:complexContent>
</xs:complexType>
</xs:schema>
For the complex type groupRestrictedType I receive these two error messages in Oxygen 7:
E rcase-RecurseLax.1: Group's occurrence range, (1,unbounded), is not a valid restriction of base group's occurrence range, (1,1).
E derivation-ok-restriction.5.4.2: Error for type 'groupRestrictedType'. The particle of the type is not a valid restriction of the particle of the base.
Compare the "invalid" type with the valid restrictedType!
What am I missing here?
Thanks,
Richard
<?xml version="1.0" encoding="UTF-8"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified" targetNamespace="http://www.ubs.com/namespace/wbml-render" xmlns="http://www.ubs.com/namespace/wbml-render" xmlns:wbr="http://www.ubs.com/namespace/wbml-render">
<xs:element name="a" type="xs:string"/>
<xs:element name="a1" type="xs:string"/>
<xs:element name="a2" type="xs:string"/>
<xs:element name="a3" type="xs:string"/>
<xs:element name="b" type="xs:integer"/>
<xs:group name="a-Group">
<xs:choice>
<xs:element ref="a1"/>
<xs:element ref="a2"/>
<xs:element ref="a3"/>
</xs:choice>
</xs:group>
<xs:complexType name="groupBaseType">
<xs:choice>
<xs:group ref="a-Group" maxOccurs="unbounded"/>
<xs:element ref="b"/>
</xs:choice>
</xs:complexType>
<xs:complexType name="groupRestrictedType">
<xs:complexContent>
<xs:restriction base="groupBaseType">
<xs:choice>
<xs:group ref="a-Group" maxOccurs="unbounded"/>
</xs:choice>
</xs:restriction>
</xs:complexContent>
</xs:complexType>
<xs:complexType name="baseType">
<xs:choice>
<xs:element ref="a" maxOccurs="unbounded"/>
<xs:element ref="b"/>
</xs:choice>
</xs:complexType>
<xs:complexType name="restrictedType">
<xs:complexContent>
<xs:restriction base="baseType">
<xs:choice>
<xs:element ref="a" maxOccurs="unbounded"/>
</xs:choice>
</xs:restriction>
</xs:complexContent>
</xs:complexType>
</xs:schema>
For the complex type groupRestrictedType I receive these two error messages in Oxygen 7:
E rcase-RecurseLax.1: Group's occurrence range, (1,unbounded), is not a valid restriction of base group's occurrence range, (1,1).
E derivation-ok-restriction.5.4.2: Error for type 'groupRestrictedType'. The particle of the type is not a valid restriction of the particle of the base.
Compare the "invalid" type with the valid restrictedType!
What am I missing here?
Thanks,
Richard
-
- Site Admin
- Posts: 2095
- Joined: Thu Jan 09, 2003 2:58 pm
Hello Richard,
I replied to your question on the xml schema dev list:
http://lists.w3.org/Archives/Public/xml ... /0012.html
In summary, Xerces is right as the main choice from the derived type is ignored as pointless occurence according to
http://www.w3.org/TR/xmlschema-1/#cos-particle-restrict
Best Regards,
George
I replied to your question on the xml schema dev list:
http://lists.w3.org/Archives/Public/xml ... /0012.html
In summary, Xerces is right as the main choice from the derived type is ignored as pointless occurence according to
http://www.w3.org/TR/xmlschema-1/#cos-particle-restrict
Best Regards,
George
Jump to
- Oxygen XML Editor/Author/Developer
- ↳ Feature Request
- ↳ Common Problems
- ↳ DITA (Editing and Publishing DITA Content)
- ↳ SDK-API, Frameworks - Document Types
- ↳ DocBook
- ↳ TEI
- ↳ XHTML
- ↳ Other Issues
- Oxygen XML Web Author
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Content Fusion
- ↳ Feature Request
- ↳ Common Problems
- Oxygen JSON Editor
- ↳ Feature Request
- ↳ Common Problems
- Oxygen PDF Chemistry
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Feedback
- ↳ Feature Request
- ↳ Common Problems
- Oxygen XML WebHelp
- ↳ Feature Request
- ↳ Common Problems
- XML
- ↳ General XML Questions
- ↳ XSLT and FOP
- ↳ XML Schemas
- ↳ XQuery
- NVDL
- ↳ General NVDL Issues
- ↳ oNVDL Related Issues
- XML Services Market
- ↳ Offer a Service