[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [Elist Home]
Subject: [xacml-comment] A schema bug?
Hello,
I have just validated the testcases updated by Anne.
Xerces still fails to validate due to some problem in <xs:complexType name
="AttributeAssignmentType">.
I'm not sure whether this is a bug in the XACML schema or a bug in Xerces.
Is there anyone who could successfully validated using Xerces?
I'd recommend to add mixed="true" to the <xs:complexType name
="AttributeAssignmentType"> definition
because it explicitly says that AttributeAssignmentType can be mixed.
I don't think that adding the attribute will cause any problem.
The current schema:
<xs:element name="AttributeAssignment" type
="xacml:AttributeAssignmentType"/>
<xs:complexType name="AttributeAssignmentType">
<xs:complexContent>
<xs:extension base="xacml:AttributeValueType">
<xs:attribute name="AttributeId" type="xs:anyURI" use="required"/>
</xs:extension>
</xs:complexContent>
</xs:complexType>
The modified schema (Note that the mixed attribute is added to the
AttributeAssignmentType):
<xs:element name="AttributeAssignment" type
="xacml:AttributeAssignmentType"/>
<xs:complexType name="AttributeAssignmentType" mixed="true">
<xs:complexContent>
<xs:extension base="xacml:AttributeValueType">
<xs:attribute name="AttributeId" type="xs:anyURI" use="required"/>
</xs:extension>
</xs:complexContent>
</xs:complexType>
Satoshi Hada
IBM Tokyo Research Laboratory
mailto:satoshih@jp.ibm.com
----- Forwarded by Satoshi Hada/Japan/IBM on 2002/11/27 11:10 -----
Satoshi Hada
To: xacml-comment <xacml-comment@lists.oasis-open.org>
2002/11/22 14:54 cc:
From: Satoshi Hada/Japan/IBM@IBMJP
Subject: A schema bug?
Hello,
I got a schema validation error when I used Xerces 2.0.1 and 2.2.0.
I can resolve this by adding mixed="true" to <xs:complexType name
="AttributeAssignmentType">.
Is this a schema bug or Xerces's bug?
org.xml.sax.SAXParseException: cos-ct-extends.1.4.2.2.2.2.1: Error for type
'Att
ributeAssignmentType'. The content type of a derived type and that of its
base
must both be mixed or element-only.
at
org.apache.xerces.util.ErrorHandlerWrapper.createSAXParseException(Un
known Source)
at org.apache.xerces.util.ErrorHandlerWrapper.error(Unknown Source)
at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown
Source)
at
org.apache.xerces.impl.xs.traversers.XSDHandler.reportSchemaError(Unk
nown Source)
at
org.apache.xerces.impl.xs.traversers.XSDAbstractTraverser.reportSchem
aError(Unknown Source)
at
org.apache.xerces.impl.xs.traversers.XSDComplexTypeTraverser.handleCo
mplexTypeError(Unknown Source)
at
org.apache.xerces.impl.xs.traversers.XSDComplexTypeTraverser.traverse
ComplexTypeDecl(Unknown Source)
at
org.apache.xerces.impl.xs.traversers.XSDComplexTypeTraverser.traverse
Global(Unknown Source)
at
org.apache.xerces.impl.xs.traversers.XSDHandler.getGlobalDecl(Unknown
Source)
at
org.apache.xerces.impl.xs.traversers.XSDElementTraverser.traverseName
dElement(Unknown Source)
at
org.apache.xerces.impl.xs.traversers.XSDElementTraverser.traverseGlob
al(Unknown Source)
at
org.apache.xerces.impl.xs.traversers.XSDHandler.traverseSchemas(Unkno
wn Source)
at
org.apache.xerces.impl.xs.traversers.XSDHandler.parseSchema(Unknown S
ource)
at org.apache.xerces.impl.xs.XMLSchemaLoader.loadSchema(Unknown
Source)
at
org.apache.xerces.impl.xs.XMLSchemaValidator.findSchemaGrammar(Unknow
n Source)
at
org.apache.xerces.impl.xs.XMLSchemaValidator.handleStartElement(Unkno
wn Source)
at
org.apache.xerces.impl.xs.XMLSchemaValidator.startElement(Unknown Sou
rce)
at
org.apache.xerces.impl.XMLNSDocumentScannerImpl.scanStartElement(Unkn
own Source)
at
org.apache.xerces.impl.XMLNSDocumentScannerImpl$NSContentDispatcher.s
canRootElementHook(Unknown Source)
at
org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContent
Dispatcher.dispatch(Unknown Source)
at
org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Un
known Source)
at org.apache.xerces.parsers.DTDConfiguration.parse(Unknown Source)
at org.apache.xerces.parsers.DTDConfiguration.parse(Unknown Source)
at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
at org.apache.xerces.parsers.DOMParser.parse(Unknown Source)
at org.apache.xerces.jaxp.DocumentBuilderImpl.parse(Unknown Source)
at
javax.xml.parsers.DocumentBuilder.parse(DocumentBuilder.java:134)
Satoshi Hada
IBM Tokyo Research Laboratory
mailto:satoshih@jp.ibm.com
[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [Elist Home]
Powered by eList eXpress LLC