Home. 
.

transparent

transparent

transparent

Altova Mailing List Archives


Re: Using non-native attributes

From: Craig Salter <csalter@--.---.--->
To: noah_mendelsohn@--.---.---
Date: 12/10/2004 6:13:00 AM
Noah,

Thanks for that  detailed clarification. I agree completely.   I was 
definitely using the term 'bug' loosely.  Techinically Xerces 2.0.0 is 
correct in complaining about the schema for schema.  In practise however 
many users do attempt to reference the schema for schema and the behaviour =

is perceived as a bug.    As you suggest, later versions of Xerces have 
infact updated their processing of the schema for schema to  'skip over' 
the built in data types and tolerate the non-conformant schema for schema.

thanks

Craig


Craig Salter
Rational Studio XML Web Services
Internal Mail: D3/RY6/8200 /MKM 
Phone: (905) 413-3918  TL: 969-3918 FAX: (905) 413-4920
Internet: csalter@c...     Notes: Craig Salter/Toronto/IBM@IBMCA





noah=5Fmendelsohn@u... 
12/10/2004 09:42 AM

To
Craig Salter/Toronto/IBM@IBMCA
cc
xmlschema-dev@w...
Subject
Re: Using non-native attributes






Craig Salter writes:

>> The XML validator in WSAD is based on Xerces  2.0.0 and hence we 
inherit one of their bugs related to process schema for schema. 

Actually, I think it's a bit more subtle than that.  The schema 
recommendation makes clear that declarations for the built in simple types =


are present by definition in every schema, without reference to the schema =


for schemas [1]:

"Similarly, simple type definitions for all the built-in derived datatypes =


(see the Derived Datatypes section of [XML Schemas: Datatypes]) are 
present by definition in every schema, with properties as specified in 
[XML Schemas: Datatypes] and as represented in XML in Schema for Schemas 
(normative) (=A7A)."

In fact, the builtin primitives are conjured up "magically".  Just as you 
cannot define your own java.lang.string in Java, you cannot define your 
own xsd:string in schema. 

For better or worse, the schema for schemas contains place holder 
definitions for these built in types, and therefore the schema for schemas =


as published is not a legal XML schema document!  So, the original 
versions of Xerces were correct in rejecting it.  As it turns out, of 
course, there are good uses for being able to use the schema for schemas 
to get at the other definitions it provides.  My impression is that 
Xerces, like some other processors, was updated to run in a mode where it 
ignored the definitions of the built in types in the specific case where 
they came from the schema for schemas, making it useful for import after 
all. 

So, I think the bottom line is that WSAD did not "inherit a bug".  Rather, =


it relied at first on a conforming version of Xerces that made it 
impossible to do what users often want to do.  Later versions picked up a 
version of Xerces that can run in a looser albeit non-conforming mode, 
enabling this scenario to work after all.

FWIW:  I think we in the schema WG blew it on making the schema for 
schemas non-conforming.  I think we should have left out the definitions 
of the builtins, resulting in a schema document that was indeed conforming =


and therefore usable in validations.

Noah

[1] http://www.w3.org/TR/xmlschema-1/#d0e16395

--------------------------------------
Noah Mendelsohn 
IBM Corporation
One Rogers Street
Cambridge, MA 02142
1-617-693-4036
--------------------------------------








Craig Salter <csalter@c...>
Sent by: xmlschema-dev-request@w...
12/09/2004 04:50 PM

 
        To:     xmlschema-dev@w...
        cc:     (bcc: Noah Mendelsohn/Cambridge/IBM)
        Subject:        Re: Using non-native attributes



Hi David, 

It sounds like Priscilla has offered the same advice that I would 
concerning the addition of the schema location and the correct way to set 
the "http://apache.org/xml/properties/schema/external-schemaLocation
",property in your Java code (the value of the propery must be a 
whitespace separated pair ... e.g. "namespace   location").

Even with this change you'll notice that older version of the Websphere 
Studio product (e.g. WSAD 512) will complain that the reference 
XMLSchema.xsd is not valid.  The XML validator in WSAD is based on Xerces 
2.0.0 and hence we inherit one of their bugs related to process schema for =


schema.  This bug is fixed in the most recent version of our product (now 
name Rational Application Developer) by virtue of updating to a newer 
version of xerces. 

BTW, schema editing and validating capability will soon be freely 
available in the open source Web Tools Project (
http://www.eclipse.org/webtools/index.html).   We're eagerly seeking 
additional contributors to the project. 

thanks

Craig


Craig Salter
Rational Studio XML Web Services
Internal Mail: D3/RY6/8200 /MKM 
Phone: (905) 413-3918  TL: 969-3918 FAX: (905) 413-4920
Internet: csalter@c...     Notes: Craig Salter/Toronto/IBM@IBMCA






transparent
Print
Mail
Like It
Disclaimer
.

These Archives are provided for informational purposes only and have been generated directly from the Altova mailing list archive system and are comprised of the lists set forth on www.altova.com/list/index.html. Therefore, Altova does not warrant or guarantee the accuracy, reliability, completeness, usefulness, non-infringement of intellectual property rights, or quality of any content on the Altova Mailing List Archive(s), regardless of who originates that content. You expressly understand and agree that you bear all risks associated with using or relying on that content. Altova will not be liable or responsible in any way for any content posted including, but not limited to, any errors or omissions in content, or for any losses or damage of any kind incurred as a result of the use of or reliance on any content. This disclaimer and limitation on liability is in addition to the disclaimers and limitations contained in the Website Terms of Use and elsewhere on the site.

.
.

transparent

transparent