You are viewing a plain text version of this content. The canonical link for it is here.
Posted to j-dev@xerces.apache.org by Guoliang Cao <ca...@ispsoft.com> on 2000/11/14 00:31:49 UTC
problem when migrates from 1.2.0 to 1.2.1. Thanks.
provRequest.xml
<?xml version="1.0"?>
<provRequest xmlns:xsi="http://www.w3.org/1999/XMLSchema-instance"
xsi:noNamespaceSchemaLocation='provRequest.xsd'>
<authToken>Auth1</authToken>
<requestID>1</requestID>
<provisionerID>cao</provisionerID>
<Priority>0</Priority>
<addAction>...
</addAction>
</provRequest>
When I use Xerces 1.2.0 to validate this document, it's OK. But if I use 1.2.1, I
always get error like:
schema error: type not found: "nowhitespacetype".
schema error: untyped element: "zone".
schema error: type not found: "IPaddressType".
schema error: untyped element: "ServerAddress".
.......
What is the possible reason?
I can assure you all files and type definitions are put into the right place.
provRequest.xsd
<schema xmlns='http://www.w3.org/1999/XMLSchema'>
<include schemaLocation="../typeDef.xsd"/>
<include schemaLocation="../exemplarDef.xsd"/>
<include schemaLocation="account.xsd"/>
<anotation>
<documentation> This is the top level schema file, includes all other
provisioning request
schema file.
</documentation>
</anotation>
<element name="provRequest" type="provRequestType"/>
<!--exemplar-->
<element name="Actions" type="ActionType"/>
<!-- equivClasses of exemplar Actions (which is defined in exemplarDef.xsd). -->
<element name="addAction" equivClass="Actions" type="addActionType"/>
<element name="editAction" equivClass="Actions" type="editActionType"/>
<element name="deleteAction" equivClass="Actions" type="deleteActionType"/>
<element name="disableAction" equivClass="Actions" type="disableActionType"/>
<element name="enableAction" equivClass="Actions" type="enableActionType"/>
<element name="viewAction" equivClass="Actions" type="viewActionType"/>
<complexType name="provRequestType">
<sequence>
<element name="authToken" type="string"/>
<element name="requestID" type="string"/>
<element name="provisionerID" type="string"/>
<element name="Priority" type="int"/>
<element ref ="Actions"/>
</sequence>
</complexType>
<complexType name="ActionType">
<sequence>
<element ref ="comment" minOccurs="0" maxOccurs="1"/>
</sequence>
</complexType>
<complexType name="addActionType" base="ActionType" derivedBy="extension">
<sequence>
<element name="Account" maxOccurs="unbounded" type="addAccountType"/>
</sequence>
</complexType>
</schema>
Re: problem when migrates from 1.2.0 to 1.2.1. Thanks.
Posted by Eric Ye <er...@locus.apache.org>.
I can reproduce the problem with 1.2.1, but I've fixed this problem in the CVS, so you can either wait for the next release, or extract the latest source from the CVS and build the jar by your self.
THX for reporting this.
_____
Eric Ye * IBM, JTC - Silicon Valley * ericye@locus.apache.org
----- Original Message -----
From: Guoliang Cao
To: xerces-j-dev@xml.apache.org ; ericye@locus.apache.org
Sent: Wednesday, November 15, 2000 8:16 AM
Subject: Re: problem when migrates from 1.2.0 to 1.2.1. Thanks.
hi, Eric,
I attached all files.
when I use
java -classpath \xerces-1_2_0\xerces.jar;\xerces-1_2_0\xercesSamples.jar sax.SAXWriter -nvs DNSService.xml
It passes the validation,
when I use xerces 1.2.1 to do the same thing, I got error.
Thanks.
Need your included schema file, cause obviously the elements and types in trouble weren't declared in your provRequest.xsd._____
Eric Ye * IBM, JTC - Silicon Valley * ericye@locus.apache.org
----- Original Message -----
From: Guoliang Cao
To: xerces-j-dev@xml.apache.org
Sent: Monday, November 13, 2000 3:31 PM
Subject: problem when migrates from 1.2.0 to 1.2.1. Thanks.
provRequest.xml
<?xml version="1.0"?>
<provRequest xmlns:xsi="http://www.w3.org/1999/XMLSchema-instance"
xsi:noNamespaceSchemaLocation='provRequest.xsd'>
<authToken>Auth1</authToken>
<requestID>1</requestID>
<provisionerID>cao</provisionerID>
<Priority>0</Priority>
<addAction>...
</addAction>
</provRequest>
When I use Xerces 1.2.0 to validate this document, it's OK. But if I use 1.2.1, I always get error like:
schema error: type not found: "nowhitespacetype".
schema error: untyped element: "zone".
schema error: type not found: "IPaddressType".
schema error: untyped element: "ServerAddress".
.......
What is the possible reason?
I can assure you all files and type definitions are put into the right place.
provRequest.xsd
<schema xmlns='http://www.w3.org/1999/XMLSchema'>
<include schemaLocation="../typeDef.xsd"/>
<include schemaLocation="../exemplarDef.xsd"/>
<include schemaLocation="account.xsd"/>
<anotation>
<documentation> This is the top level schema file, includes all other provisioning request
schema file.
</documentation>
</anotation>
<element name="provRequest" type="provRequestType"/>
<!--exemplar-->
<element name="Actions" type="ActionType"/>
<!-- equivClasses of exemplar Actions (which is defined in exemplarDef.xsd). -->
<element name="addAction" equivClass="Actions" type="addActionType"/>
<element name="editAction" equivClass="Actions" type="editActionType"/>
<element name="deleteAction" equivClass="Actions" type="deleteActionType"/>
<element name="disableAction" equivClass="Actions" type="disableActionType"/>
<element name="enableAction" equivClass="Actions" type="enableActionType"/>
<element name="viewAction" equivClass="Actions" type="viewActionType"/>
<complexType name="provRequestType">
<sequence>
<element name="authToken" type="string"/>
<element name="requestID" type="string"/>
<element name="provisionerID" type="string"/>
<element name="Priority" type="int"/>
<element ref ="Actions"/>
</sequence>
</complexType>
<complexType name="ActionType">
<sequence>
<element ref ="comment" minOccurs="0" maxOccurs="1"/>
</sequence>
</complexType>
<complexType name="addActionType" base="ActionType" derivedBy="extension">
<sequence>
<element name="Account" maxOccurs="unbounded" type="addAccountType"/>
</sequence>
</complexType>
</schema>
------------------------------------------------------------------------------
<schema>
<annotation>
<documentation>Created By cao@ispsoft.com. Used for defining share types.
</documentation>
</annotation>
<!-- Bool, EmailAddressType, HostNameType, IpAddressType, PhoneNumberType, ServiceNameType,
UserNameType are types used in other type definitions -->
<simpleType name="Bool" base="string">
<enumeration value="true"/>
<enumeration value="false"/>
</simpleType>
<simpleType name="EmailAddressType" base="string">
<pattern value="[a-zA-Z]([a-zA-Z0-9\-\_\.])*([a-zA-Z0-9\-\_]*)\@([a-zA-Z0-9\-\_]+\.)+[a-zA-Z]+"/>
</simpleType>
<simpleType name="HostNameType" base="string">
<pattern value="([a-zA-Z][a-zA-Z0-9\-\_]*\.)*[a-zA-Z]+"/>
</simpleType>
<simpleType name="IPaddressType" base="string">
<pattern value="[0-2]?[0-9]{1,2}\.[0-2]?[0-9]{1,2}\.[0-2]?[0-9]{1,2}\.[0-2]?[0-9]{1,2}"/>
</simpleType>
<simpleType name="LoginShellType" base="string">
<enumeration value="Bash"/>
<enumeration value="Csh"/>
<enumeration value="Tcsh"/>
<enumeration value="Ksh"/>
</simpleType>
<simpleType name="PhoneNumberType" base="string">
<pattern value="(\([0-9]{3}\)[0-9]{3}\-[0-9]{4})|((1\-)?[0-9]{3}\-[0-9]{3}-[0-9]{4})"/>
</simpleType>
<simpleType name="UserNameType" base="string">
<pattern value="[_a-zA-Z][_0-9a-zA-Z]*"/>
</simpleType>
<!-- Nov 8, 2000 -->
<simpleType name="NoWhitespaceType" base="string">
<pattern value=".*\S.*"/>
</simpleType>
</schema>
------------------------------------------------------------------------------
<schema>
<!-- type of <addDNSInstance>, derived from ServiceInstanceType, used in addAction.xsd -->
<complexType name="addDNSInstanceType" derivedBy="extension">
<sequence>
<element name="ZoneName" minOccurs="1" type="NoWhitespaceType"/>
<element name="RevZoneName" minOccurs="0" type="NoWhitespaceType"/>
<element name="addRR" minOccurs="0" maxOccurs="unbounded" type="addRRType"/>
<element name="ServerAddress" minOccurs="1" type="IPaddressType"/>
</sequence>
</complexType>
<complexType name="addRRType">
<sequence>
<element name="RRName" minOccurs="1" type="NoWhitespaceType"/>
<element name="RRType" minOccurs="1" type="NoWhitespaceType"/>
<element name="RRData" minOccurs="1" type="NoWhitespaceType"/>
<element name="Priority" minOccurs="0" type="int"/>
</sequence>
</complexType>
</schema>
------------------------------------------------------------------------------
<schema xmlns='http://www.w3.org/1999/XMLSchema'>
<!-- include other schema files for detail definition for each action.-->
<include schemaLocation="typeDef.xsd"/>
<include schemaLocation="DNSService.xsd"/>
<element name="provRequest" type="provRequestType"/>
<complexType name="provRequestType">
<sequence>
<element name="addDNSInstance" type="addDNSInstanceType"/>
</sequence>
</complexType>
</schema>
------------------------------------------------------------------------------
<?xml version="1.0"?>
<provRequest xmlns:xsi="http://www.w3.org/1999/XMLSchema-instance"
xsi:noNamespaceSchemaLocation='provRequest.xsd'>
<addDNSInstance>
<ZoneName>myZone</ZoneName> <!-- [1] string -->
<RevZoneName>revzone</RevZoneName> <!-- string -->
<addRR>
<RRName>a_name</RRName> <!-- [1] string -->
<RRType>record_type</RRType> <!-- [1] string -->
<RRData>some_data</RRData> <!-- [1] string -->
<Priority>10</Priority> <!-- integer -->
</addRR>
<ServerAddress>1.1.1.1</ServerAddress>
</addDNSInstance>
</provRequest>
------------------------------------------------------------------------------
---------------------------------------------------------------------
To unsubscribe, e-mail: xerces-j-dev-unsubscribe@xml.apache.org
For additional commands, e-mail: xerces-j-dev-help@xml.apache.org
Re: problem when migrates from 1.2.0 to 1.2.1. Thanks.
Posted by Guoliang Cao <ca...@ispsoft.com>.
hi, Eric,
I attached all files.
when I use
java -classpath \xerces-1_2_0\xerces.jar;\xerces-1_2_0\xercesSamples.jar
sax.SAXWriter -nvs DNSService.xml
It passes the validation,
when I use xerces 1.2.1 to do the same thing, I got error.
Thanks.
> Need your included schema file, cause obviously the elements and types
> in trouble weren't declared in your provRequest.xsd._____
> Eric Ye * IBM, JTC - Silicon Valley * ericye@locus.apache.org
>
> ----- Original Message -----
> From: Guoliang Cao
> To: xerces-j-dev@xml.apache.org
> Sent: Monday, November 13, 2000 3:31 PM
> Subject: problem when migrates from 1.2.0 to 1.2.1. Thanks.
> provRequest.xml
>
> <?xml version="1.0"?>
> <provRequest
> xmlns:xsi="http://www.w3.org/1999/XMLSchema-instance"
> xsi:noNamespaceSchemaLocation='provRequest.xsd'>
> <authToken>Auth1</authToken>
> <requestID>1</requestID>
> <provisionerID>cao</provisionerID>
> <Priority>0</Priority>
> <addAction>...
> </addAction>
> </provRequest>
>
> When I use Xerces 1.2.0 to validate this document, it's OK.
> But if I use 1.2.1, I always get error like:
>
> schema error: type not found: "nowhitespacetype".
> schema error: untyped element: "zone".
> schema error: type not found: "IPaddressType".
> schema error: untyped element: "ServerAddress".
> .......
>
> What is the possible reason?
>
> I can assure you all files and type definitions are put into
> the right place.
>
> provRequest.xsd
>
> <schema xmlns='http://www.w3.org/1999/XMLSchema'>
> <include schemaLocation="../typeDef.xsd"/>
> <include schemaLocation="../exemplarDef.xsd"/>
> <include schemaLocation="account.xsd"/>
>
> <anotation>
> <documentation> This is the top level schema file,
> includes all other provisioning request
> schema file.
> </documentation>
> </anotation>
>
> <element name="provRequest" type="provRequestType"/>
>
> <!--exemplar-->
> <element name="Actions" type="ActionType"/>
>
> <!-- equivClasses of exemplar Actions (which is defined in
> exemplarDef.xsd). -->
> <element name="addAction" equivClass="Actions"
> type="addActionType"/>
> <element name="editAction" equivClass="Actions"
> type="editActionType"/>
> <element name="deleteAction" equivClass="Actions"
> type="deleteActionType"/>
> <element name="disableAction" equivClass="Actions"
> type="disableActionType"/>
> <element name="enableAction" equivClass="Actions"
> type="enableActionType"/>
> <element name="viewAction" equivClass="Actions"
> type="viewActionType"/>
>
> <complexType name="provRequestType">
> <sequence>
> <element name="authToken" type="string"/>
> <element name="requestID" type="string"/>
> <element name="provisionerID" type="string"/>
> <element name="Priority" type="int"/>
> <element ref ="Actions"/>
> </sequence>
> </complexType>
>
> <complexType name="ActionType">
> <sequence>
> <element ref ="comment" minOccurs="0" maxOccurs="1"/>
> </sequence>
> </complexType>
>
> <complexType name="addActionType" base="ActionType"
> derivedBy="extension">
> <sequence>
> <element name="Account" maxOccurs="unbounded"
> type="addAccountType"/>
> </sequence>
> </complexType>
>
> </schema>
>
>
>
>
Re: problem when migrates from 1.2.0 to 1.2.1. Thanks.
Posted by Eric Ye <er...@locus.apache.org>.
Need your included schema file, cause obviously the elements and types in trouble weren't declared in your provRequest.xsd.
_____
Eric Ye * IBM, JTC - Silicon Valley * ericye@locus.apache.org
----- Original Message -----
From: Guoliang Cao
To: xerces-j-dev@xml.apache.org
Sent: Monday, November 13, 2000 3:31 PM
Subject: problem when migrates from 1.2.0 to 1.2.1. Thanks.
provRequest.xml
<?xml version="1.0"?>
<provRequest xmlns:xsi="http://www.w3.org/1999/XMLSchema-instance"
xsi:noNamespaceSchemaLocation='provRequest.xsd'>
<authToken>Auth1</authToken>
<requestID>1</requestID>
<provisionerID>cao</provisionerID>
<Priority>0</Priority>
<addAction>...
</addAction>
</provRequest>
When I use Xerces 1.2.0 to validate this document, it's OK. But if I use 1.2.1, I always get error like:
schema error: type not found: "nowhitespacetype".
schema error: untyped element: "zone".
schema error: type not found: "IPaddressType".
schema error: untyped element: "ServerAddress".
.......
What is the possible reason?
I can assure you all files and type definitions are put into the right place.
provRequest.xsd
<schema xmlns='http://www.w3.org/1999/XMLSchema'>
<include schemaLocation="../typeDef.xsd"/>
<include schemaLocation="../exemplarDef.xsd"/>
<include schemaLocation="account.xsd"/>
<anotation>
<documentation> This is the top level schema file, includes all other provisioning request
schema file.
</documentation>
</anotation>
<element name="provRequest" type="provRequestType"/>
<!--exemplar-->
<element name="Actions" type="ActionType"/>
<!-- equivClasses of exemplar Actions (which is defined in exemplarDef.xsd). -->
<element name="addAction" equivClass="Actions" type="addActionType"/>
<element name="editAction" equivClass="Actions" type="editActionType"/>
<element name="deleteAction" equivClass="Actions" type="deleteActionType"/>
<element name="disableAction" equivClass="Actions" type="disableActionType"/>
<element name="enableAction" equivClass="Actions" type="enableActionType"/>
<element name="viewAction" equivClass="Actions" type="viewActionType"/>
<complexType name="provRequestType">
<sequence>
<element name="authToken" type="string"/>
<element name="requestID" type="string"/>
<element name="provisionerID" type="string"/>
<element name="Priority" type="int"/>
<element ref ="Actions"/>
</sequence>
</complexType>
<complexType name="ActionType">
<sequence>
<element ref ="comment" minOccurs="0" maxOccurs="1"/>
</sequence>
</complexType>
<complexType name="addActionType" base="ActionType" derivedBy="extension">
<sequence>
<element name="Account" maxOccurs="unbounded" type="addAccountType"/>
</sequence>
</complexType>
</schema>