W3C home > Mailing lists > Public > w3c-rdfcore-wg@w3.org > August 2001

<rdf:RDF> optional? (was Re: RDF/XML Syntax Internal Working Draft V1.23 )

From: Dave Beckett <dave.beckett@bristol.ac.uk>
Date: Tue, 28 Aug 2001 17:17:18 +0100
To: RDF Core <w3c-rdfcore-wg@w3.org>
CC: Aaron Swartz <aswartz@upclink.com>
Message-ID: <30550.999015438@tatooine.ilrt.bris.ac.uk>
>>>Aaron Swartz said:
> For production 6.1 you write that RDF can be:
> 	"<rdf:RDF>" description* "</rdf:RDF>" | description
> This is a pretty big change, since M&S never allowed RDF 
> documents without their surrounding <rdf:RDF> tags. I don't 
> believe the Working Group ever made a decision on this issue. 
> I'm not certain that I disagree with it, but I feel it's 
> important for the WG to be aware of the issue.

The original grammar says in
  [6.1] RDF ::= ['<rdf:RDF>'] obj* ['</rdf:RDF>']

and the '[' ... ']' mean optional, at least that's how I interpreted
it.  It doesn't seem be used correctly according to the referred notation:

I would have expected this, if rdf:RDF wasn't optional:
  [6.1] RDF ::= '<rdf:RDF>' obj* '</rdf:RDF>'

Ahah, a quote from 2.2.1

  The RDF element is a simple wrapper that marks the boundaries in an
  XML document between which the content is explicitly intended to be
  mappable into an RDF data model instance. The RDF element is
  optional if the content can be known to be RDF from the application

So it does allow it to be omitted.  Context to me could include,
seeing an rdf:about or other rdf: attribute on the element.  For
example, is this legal?

  <?xml version="1.0"?>
  <a:foo  xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"

SiRPAC (W3C version): no statements, no error
ARP: no statements, no error
Raptor (me): 1 statement
CARA: "No RDF found!" error
Profium RDF Parser: no statements, no error

Looks like I'm out of line here :)  I thought it would be useful for
hunting for embedded RDF fragments in XML.

So thanks for raising this Aaron - I guess you own the issue :)

Received on Tuesday, 28 August 2001 12:18:13 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 20:24:03 UTC