RDF/XML Syntax - reifying using XML attributes only

I thought of this test case while talking to Jan Grant, and having
chatted with it off-list with some of the syntax-ers (Art, Jan,
Jeremy), we feel this is broken but had no consensus on fixing it.

Pretty clearly when rdf:type is used as a property attribute, it is
defined to take a resource as a value (this is in the grammar).  What
is not so clear is when the other rdf: properties are used.
rdf:subject and rdf:predicate (unless RDF Schema ranges are used)
take a URI as value and this is OK.  rdf:object as an attribute can
take literal or URI, and we can't tell them apart as attribute
content.

One interpretation would be that only literals are allowed as objects
in this form in which case the RDF/XML attached below reifies the
single statement
  <http://example.com/resource1> <http://example.com/predicate> "literal" .
into the attached N-Triples.

The various parsers do different things on this RDF/XML - which is
wrong - so we must define one way or forbid it.

The attribute forms are only abbreviations of the more expressive
element form so there need not be a way to provide literal and URIs
for rdf:object statement values.

I guess this is another syntax issue.  Brian - please record it and I
guess since I raised it, it belongs to me :(

Dave
<?xml version="1.0"?>
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
  <!-- Test reified statement using attributes only -->
  <rdf:Description rdf:type="http://www.w3.org/1999/02/22-rdf-syntax-ns#Statement"
                   rdf:subject="http://example.com/resource"
                   rdf:predicate="http://example.com/predicate"
                   rdf:object="literal" />
</rdf:RDF>
_:id1 <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.w3.org/1999/02/22-rdf-syntax-ns#Statement> .
_:id1 <http://www.w3.org/1999/02/22-rdf-syntax-ns#subject> <http://example.com/resource> .
_:id1 <http://www.w3.org/1999/02/22-rdf-syntax-ns#predicate> <http://example.com/predicate> .
_:id1 <http://www.w3.org/1999/02/22-rdf-syntax-ns#object> "literal" .

Received on Tuesday, 21 August 2001 11:21:19 UTC