- From: Dave Beckett <dave.beckett@bristol.ac.uk>
- Date: Fri, 25 Oct 2002 13:06:42 +0100
- To: www-archive@w3.org
- Message-ID: <11982.1035547602@hoth.ilrt.bris.ac.uk>
This is http://ilrt.org/discovery/2001/07/rdf-syntax-grammar/ CVS version 1.350 Full CVS history at http://cvs.ilrt.org/cvsweb/redland/rdfcore/syntax/index.html Dave
# # RELAX NG Schema (non-XML) for RDF/XML Syntax # # This schema is for information only and NON-NORMATIVE # # It is based on one originally written by James Clark in # http://lists.w3.org/Archives/Public/www-rdf-comments/2001JulSep/0248.html # and updated with later changes. # namespace local = "" namespace rdf = "http://www.w3.org/1999/02/22-rdf-syntax-ns#" datatypes xsd = "http://www.w3.org/2001/XMLSchema-datatypes" start = doc doc = RDF RDF = element rdf:RDF { nodeElementList } nodeElementList = nodeElement* # Should be something like: # ws* , ( nodeElement , ws* )* # but RELAXNG does this by default, ignoring whitespace separating tags. nodeElement = element * - (local:* |rdf:RDF |rdf:ID|rdf:about |rdf:bagID|rdf:parseType|rdf:resource |rdf:li ) { (idAttr | aboutAttr )?, bagIdAttr?, propertyAttr*, propertyEltList } # It is not possible to say "and not things # beginning with _ in the rdf: namespace" in RELAX NG. ws = " " # Not used in this RELAX NG schema; but should be any legal XML # whitespace defined by http://www.w3.org/TR/2000/REC-xml-20001006#NT-S propertyEltList = propertyElt* # Should be something like: # ws* , ( propertyElt , ws* )* # but RELAXNG does this by default, ignoring whitespace separating tags. propertyElt = resourcePropertyElt | literalPropertyElt | parseTypeLiteralPropertyElt | parseTypeResourcePropertyElt | parseTypeOtherPropertyElt | emptyPropertyElt resourcePropertyElt = element * - (local:* |rdf:RDF|rdf:Description |rdf:ID|rdf:about |rdf:bagID|rdf:parseType|rdf:resource) { idAttr?, nodeElement } literalPropertyElt = element * - (local:* |rdf:RDF|rdf:Description |rdf:ID|rdf:about |rdf:bagID|rdf:parseType|rdf:resource) { idAttr?, text } parseTypeLiteralPropertyElt = element * - (local:* |rdf:RDF|rdf:Description |rdf:ID|rdf:about |rdf:bagID|rdf:parseType|rdf:resource) { idAttr?, parseLiteral, literal } parseTypeResourcePropertyElt = element * - (local:* |rdf:RDF|rdf:Description |rdf:ID|rdf:about |rdf:bagID|rdf:parseType|rdf:resource) { idAttr?, parseResource, propertyEltList } parseTypeOtherPropertyElt = element * - (local:* |rdf:RDF|rdf:Description |rdf:ID|rdf:about |rdf:bagID|rdf:parseType|rdf:resource) { idAttr?, parseOther, any } emptyPropertyElt = element * - (local:* |rdf:RDF|rdf:Description |rdf:ID|rdf:about |rdf:bagID|rdf:parseType|rdf:resource) { idAttr?, resourceAttr?, bagIdAttr?, propertyAttr* } idAttr = attribute rdf:ID { IDsymbol } aboutAttr = attribute rdf:about { URI-reference } bagIdAttr = attribute rdf:bagID { IDsymbol } propertyAttr = attribute * - (local:* |rdf:RDF|rdf:Description |rdf:ID|rdf:about |rdf:bagID|rdf:parseType|rdf:resource |rdf:li) { string } resourceAttr = attribute rdf:resource { URI-reference } parseLiteral = attribute rdf:parseType { "Literal" } parseResource = attribute rdf:parseType { "Resource" } parseOther = attribute rdf:parseType { text } URI-reference = string literal = any IDsymbol = xsd:NMTOKEN any = mixed { element * { attribute * { text }*, any }* }
Attachments
- text/html attachment: index.html
- image/png attachment: figure1.png
- image/png attachment: figure2.png
- application/svg+xml attachment: figure1.svg
- application/svg+xml attachment: figure2.svg
- application/rdf+xml attachment: example07.rdf
- application/rdf+xml attachment: example08.rdf
- application/rdf+xml attachment: example09.rdf
- application/rdf+xml attachment: example10.rdf
- application/rdf+xml attachment: example11.rdf
- application/rdf+xml attachment: example12.rdf
- application/rdf+xml attachment: example13.rdf
- application/rdf+xml attachment: example14.rdf
- application/rdf+xml attachment: example15.rdf
- application/rdf+xml attachment: example16.rdf
- application/rdf+xml attachment: example17.rdf
- application/rdf+xml attachment: example18.rdf
- application/rdf+xml attachment: example19.rdf
- application/rdf+xml attachment: example20.rdf
- application/rdf+xml attachment: example21.rdf
- application/rdf+xml attachment: metadata.rdf
- application/xml attachment: rdfxml.xml
Received on Friday, 25 October 2002 08:08:06 UTC