Re: Re[2]: XML namespaces and RDF

Hi Richard,

It's also worth mentioning CURIEs [1] which is an attempt to solve the
problems that arise when using QNames to abbreviate URIs.

The main problem with QNames is that not all URIs can be abbreviated
in this manner. But the second problem is that QNames originate in XML
and have a very specific purpose, which makes their use outside of
XML--such as in earlier drafts of SPARQL, and in N3--a bit of a hack.

Regards,

Mark

[1] <http://www.w3.org/TR/curie/>

On 13/12/2007, Richard Cyganiak <richard@cyganiak.de> wrote:
>
> Max,
>
> On 13 Dec 2007, at 19:20, Max Voelkel wrote:
> >  is    there    anywhere   a   general   rule   *defined*   how
> > to   expand
> >  namespace-prefixed-XML-localnames  such  as  xs:dayTimeDuration
> > into  a  full
> >  (possibly de-referencable) URI?
>
> The prefix:localname syntax is used all over the RDF world, but
> nevertheless it is *not* part of the core RDF standard. There's no
> single place where it is defined. The RDF abstract model doesn't know
> about this abbreviation mechanism at all; it just knows about fullly
> expanded, absolute URIs.
>
> The prefix:localname syntax is just a convention that is used in
> multiple RDF serialization formats and other RDF-related standards, to
> the point where it has become ubiquitous. Hence you have to consult
> the specs for the individual formats that use this syntax.
>
> For RDF/XML, try this:
> http://www.w3.org/TR/rdf-syntax-grammar/#section-Identifiers
>
> "Within RDF/XML, XML QNames are transformed into RDF URI references by
> appending the XML local name to the namespace name (URI reference).
> For example, if the XML namespace prefix foo has namespace name (URI
> reference)http://example.org/somewhere/ then the QName foo:bar would
> correspond to the RDF URI referencehttp://example.org/somewhere/bar.
> Note that this restricts which RDF URI references can be made and the
> same URI can be given in multiple ways."
>
> For Turtle, try section 2.1:
> http://www.dajobe.org/2004/01/turtle/#sec-tutorial
>
> "Once a prefix such as @prefix foo: <http://example.org/ns#> is
> defined, any mention of a URI later in the document may use a
> qualified name that starts foo: to stand for the longer URI. So for
> example, the qualified name foo:bar is a shorthand for the URI http://example.org/ns#bar
> ."
>
> SPARQL also has it:
> http://www.w3.org/TR/rdf-sparql-query/#QSynIRI
>
> "The PREFIX keyword associates a prefix label with an IRI. A prefixed
> name is a prefix label and a local part, separated by a colon ":". A
> prefixed name is mapped to an IRI by concatenating the IRI associated
> with the prefix and the local part. The prefix label or the local part
> may be empty. Note that SPARQL local names allow leading digits while
> XML local names do not."
>
> I'm sure there are more.
>
> Best,
> Richard
>
>
>
> >
> >
> > ----------
> > in http://www.w3.org/TR/xpath-datamodel/#notation it says:
> > ----
> > The following bindings are assumed.
> > xs: bound to http://www.w3.org/2001/XMLSchema
> > ----
> >
> > This implies from XML namespace rules that e.g.
> > xs:dayTimeDuration  expands to
> > http://www.w3.org/2001/XMLSchemadayTimeDuration
> > which is not a dereferencable URI.
> >
> > Is   this correct and intended? For RDF, one uses usually namespace
> > declarations
> > that end with "/" or "#".
> >
> > Michael Rys responds:
> > MR> Namespace prefixes in XML are not concatenated to the names in
> > the way that
> > MR> you do it below. Instead they form a tuple
> > MR> (namespace-uri, local-name).
> >
> > MR> There are different expanded name notations being used, such as
> > MR> {http://www.w3.org/2001/XMLSchema}dayTimeDuration,
> > MR> which is non-dereferencable, or
> > MR> http://www.w3.org/2001/XMLSchema#dayTimeDuration which can be.
> >
> > Thanks  a  lot for your quick response. Is there a sort of
> > authorative "expanded
> > name   notation"?   Especially  one  talking  about  "#"  would
> > be  great  to
> > read/reference. I have no idea what to Google for.
> >
> > [1] 'defines' (but only in the examples) the rule: <url> =
> > <namespace> + <localname>
> >
> > [1] http://www.w3.org/TR/rdf-primer/
> >
> > Kind Regards,
> > Max
> > --
> >       Max Völkel
> >       voelkel@fzi.de | www.Xam.de
> >       office     +49 721 96 54-854
> >       mobile     +49 171 83 59 678
> > --
> > FZI Forschungszentrum Informatik an der Universität Karlsruhe
> > Haid-und-Neu-Str. 10-14, D-76131 Karlsruhe
> > Tel.: +49-721-9654-0, Fax: +49-721-9654-959
> > Stiftung des bürgerlichen Rechts, Az: 14-0563.1 Regierungspräsidium
> > Karlsruhe.
> > Vorstand: Prof. Dr.-Ing. Rüdiger Dillmann, Dipl. Wi.-Ing. Michael Flor
> > Prof. Dr. Dr.-Ing. Jivka Ovtcharova, Prof. Dr. rer. nat. Rudi Studer
> > Vorsitzender des Kuratoriums: Ministerialdirigent Günther Leßnerkraus
> >
> >
> >
>
>
>


-- 
  Mark Birbeck, formsPlayer

  mark.birbeck@formsPlayer.com | +44 (0) 20 7689 9232
  http://www.formsPlayer.com | http://internet-apps.blogspot.com

  standards. innovation.

Received on Friday, 14 December 2007 00:32:26 UTC