W3C home > Mailing lists > Public > www-rdf-interest@w3.org > March 2002

RE: parseType="literal"

From: Jeremy Carroll <jjc@hplb.hpl.hp.com>
Date: Tue, 12 Mar 2002 09:46:01 -0000
To: "Danny Ayers" <danny666@virgilio.it>, <tarod@softhome.net>
Cc: <www-rdf-interest@w3.org>
Message-ID: <JAEBJCLMIFLKLOJGMELDMEENCDAA.jjc@hplb.hpl.hp.com>

> The rest of the material posted makes sense to me, but I have trouble with
> the example below - by any (current) reckoning, surely "q:name" is just a
> literal string itself here (nothing can cross the quote
> threshold), and has
> no connection whatsoever to the earlier xmlns:q=... (without making a
> significant revision of the XML spec)??
[ example at end ]

You'd have thought so.

But ... XML Schema allows qnames in attribute values e.g.
xsi:type="xsd:decimal" where the xsd is a namespace prefix and must be bound
to the appropriate URI. XSLT allows XPath expressions in attribute values,
these again use namespace prefixes as prefixes - i.e. they must be bound to
the right URI.

An example in the XSLT I wrote in the RDF Core posting is from extract.xsl:

<xsl:template match="*[@rdf:parseType='Literal']"
    <xsl:apply-templates select="node()" mode="copy"/>

To match an element with an rdf:parseType="Literal" attribute namespace use
within attribute values is required.

A way RDF/XML could go is to simply not support (allow) namespace prefixes
within attribute values within xml literals within RDF! I think currently is
a theoretical requirement without any actual users.

> 3: Difficulties with QNames as Attribute Values
> ===============================================
> Moving on to example 7 a_7.xml:
> [[[
> <rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
>    xmlns:eg="http://example.org/"
>    xmlns:q="http://example.org/q"  >
>    <rdf:Description>
>      <eg:a rdf:parseType="Literal">
>          <foo bar="q:name"/>
>      </eg:a>
>    </rdf:Description>
> </rdf:RDF>
> ]]]

Received on Tuesday, 12 March 2002 04:47:10 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 7 January 2015 15:07:39 UTC