diff options
author | Brion Vibber <brion@pobox.com> | 2009-11-19 21:05:31 -0800 |
---|---|---|
committer | Brion Vibber <brion@pobox.com> | 2009-11-19 21:05:31 -0800 |
commit | 512445e641b696962a9d5fb2de4147270545a13a (patch) | |
tree | 89eae38f77e74b51478cc2ec0c13a0ac249d75ba /plugins/FeedSub/extlib/XML/Feed/schemas/rss10.rnc | |
parent | 584b17a8185bc4f2b501e94b1e3c942234f0d646 (diff) | |
parent | dd36c2de23dbdb30f333be1f9d5292d62363b0c8 (diff) |
Merge branch 'feed-integration' into 0.9.x
Diffstat (limited to 'plugins/FeedSub/extlib/XML/Feed/schemas/rss10.rnc')
-rwxr-xr-x | plugins/FeedSub/extlib/XML/Feed/schemas/rss10.rnc | 113 |
1 files changed, 113 insertions, 0 deletions
diff --git a/plugins/FeedSub/extlib/XML/Feed/schemas/rss10.rnc b/plugins/FeedSub/extlib/XML/Feed/schemas/rss10.rnc new file mode 100755 index 000000000..725094788 --- /dev/null +++ b/plugins/FeedSub/extlib/XML/Feed/schemas/rss10.rnc @@ -0,0 +1,113 @@ +<?xml version='1.0' encoding='UTF-8'?> +<!-- http://www.xml.com/lpt/a/2002/01/23/relaxng.html --> +<!-- http://www.oasis-open.org/committees/relax-ng/tutorial-20011203.html --> +<!-- http://www.zvon.org/xxl/XMLSchemaTutorial/Output/ser_wildcards_st8.html --> + +<grammar xmlns='http://relaxng.org/ns/structure/1.0' + xmlns:rdf='http://www.w3.org/1999/02/22-rdf-syntax-ns#' + xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance' + ns='http://purl.org/rss/1.0/' + datatypeLibrary='http://www.w3.org/2001/XMLSchema-datatypes'> + + <start> + <element name='RDF' ns='http://www.w3.org/1999/02/22-rdf-syntax-ns#'> + <ref name='RDFContent'/> + </element> + </start> + + <define name='RDFContent' ns='http://purl.org/rss/1.0/'> + <interleave> + <element name='channel'> + <ref name='channelContent'/> + </element> + <optional> + <element name='image'><ref name='imageContent'/></element> + </optional> + <oneOrMore> + <element name='item'><ref name='itemContent'/></element> + </oneOrMore> + </interleave> + </define> + + <define name='channelContent' combine="interleave"> + <interleave> + <element name='title'><data type='string'/></element> + <element name='link'><data type='anyURI'/></element> + <element name='description'><data type='string'/></element> + <element name='image'> + <attribute name='resource' ns='http://www.w3.org/1999/02/22-rdf-syntax-ns#'> + <data type='anyURI'/> + </attribute> + </element> + <element name='items'> + <ref name='itemsContent'/> + </element> + <attribute name='about' ns='http://www.w3.org/1999/02/22-rdf-syntax-ns#'> + <data type='anyURI'/> + </attribute> + </interleave> + </define> + + <define name="itemsContent"> + <element name="Seq" ns='http://www.w3.org/1999/02/22-rdf-syntax-ns#'> + <oneOrMore> + <element name="li" ns='http://www.w3.org/1999/02/22-rdf-syntax-ns#'> + <choice> + <attribute name='resource'> <!-- Why doesn't RDF/RSS1.0 ns qualify this attribute? --> + <data type='anyURI'/> + </attribute> + <attribute name='resource' ns='http://www.w3.org/1999/02/22-rdf-syntax-ns#'> + <data type='anyURI'/> + </attribute> + </choice> + </element> + </oneOrMore> + </element> + </define> + + <define name='imageContent'> + <interleave> + <element name='title'><data type='string'/></element> + <element name='link'><data type='anyURI'/></element> + <element name='url'><data type='anyURI'/></element> + <attribute name='about' ns='http://www.w3.org/1999/02/22-rdf-syntax-ns#'> + <data type='anyURI'/> + </attribute> + </interleave> + </define> + + <define name='itemContent'> + <interleave> + <element name='title'><data type='string'/></element> + <element name='link'><data type='anyURI'/></element> + <optional><element name='description'><data type='string'/></element></optional> + <ref name="anyThing"/> + <attribute name='about' ns='http://www.w3.org/1999/02/22-rdf-syntax-ns#'> + <data type='anyURI'/> + </attribute> + </interleave> + </define> + + + <define name='anyThing'> + <zeroOrMore> + <choice> + <text/> + <element> + <anyName> + <except> + <nsName/> + </except> + </anyName> + <ref name='anyThing'/> + <zeroOrMore> + <attribute> + <anyName/> + </attribute> + </zeroOrMore> + </element> + </choice> + </zeroOrMore> + </define> + +</grammar> |