W3C home > Mailing lists > Public > public-owl-wg@w3.org > August 2009

Re: Prefix names cannot be empty according to the OWL/XML schema

From: Bijan Parsia <bparsia@cs.man.ac.uk>
Date: Fri, 7 Aug 2009 11:13:35 +0100
Cc: 'W3C OWL Working Group' <public-owl-wg@w3.org>
Message-Id: <A4E88F86-BB56-44C5-BEAD-1E49DE1CEBB1@cs.man.ac.uk>
To: Antoine Zimmermann <antoine.zimmermann@deri.org>
On 7 Aug 2009, at 10:53, Antoine Zimmermann wrote:

> Dear all,
> According to the XML Schema of the OWL/XML syntax, the element  
> Prefix must have a name which is a xsd:string of the form:
> "(&PN_CHARS_BASE;)((&PN_CHARS;|\.)*(&PN_CHARS;  ))?"
> where &PN_CHARS_BASE; is a character. So the Prefix must be  
> nonempty. This makes many examples in the test cases invalid. This  
> is obviously a bug in the Schema, not in the examples.

Good catch.

It's a bug internal to the schema as well.
allows for references without prefixes. But the current prefix element  
gives no way to bind a uri to the null prefix.
(It also makes abbreviated URIs with no prefix have a leading :. Ugly,  
though consistent with sparl and FS.)
The fix is simple:
   <xsd:complexType name="Prefix">
     <xsd:attribute name="name" use="required">
         <xsd:restriction base="xsd:string">
           <xsd:pattern value="&PN_PREFIX;|"/>
     <xsd:attribute name="IRI" type="xsd:anyURI" use="required"/>
(I think it's better to do this in the regular expression here than in  
&PN_PREFIX; so &PN_PREFIX; remains identical to the sparql version.)
Received on Friday, 7 August 2009 10:14:11 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 21:42:13 UTC