manually input Collection and Membership inline schema fragments and example XML
authorStephan Zednik <zednis@rpi.edu>
Thu, 25 Oct 2012 10:02:47 -0600
changeset 4555 1f11f244d05d
parent 4554 a4d591af7035
child 4556 8f98638687a1
manually input Collection and Membership inline schema fragments and example XML
xml/prov-xml.html
--- a/xml/prov-xml.html	Thu Oct 25 15:44:43 2012 +0100
+++ b/xml/prov-xml.html	Thu Oct 25 10:02:47 2012 -0600
@@ -707,7 +707,7 @@
 <div class="glossary-ref" data-ref="glossary-entity"></div>
 <div class="schema-type" data-name="prov:Entity" data-include="schema/prov.xsd" data-oninclude="insertSchema_Entity"></div>
 <div class="schema-usage" data-include="schema/prov.xsd" data-oninclude="insertSchema_entity"></div>
-<pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Entity.xml" data-oninclude="formatExample"></pre>
+<!-- <pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Entity.xml" data-oninclude="formatExample"></pre> -->
 </section> <!-- end term-Entity -->
 
 <section id="term-Activity"> 
@@ -715,7 +715,7 @@
 <div class="glossary-ref" data-ref="glossary-activity"></div>
 <div class="schema-type" data-name="prov:Activity" data-include="schema/prov.xsd" data-oninclude="insertSchema_Activity"></div>
 <div class="schema-usage" data-include="schema/prov.xsd" data-oninclude="insertSchema_activity"></div>
-<pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Activity.xml" data-oninclude="formatExample"></pre>
+<!-- <pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Activity.xml" data-oninclude="formatExample"></pre> -->
 </section> <!-- end term-Activity -->
 
 <section id="term-Generation">
@@ -723,7 +723,7 @@
 <div class="glossary-ref" data-ref="glossary-generation"></div>
 <div class="schema-type" data-name="prov:Generation" data-include="schema/prov.xsd" data-oninclude="insertSchema_Generation"></div>
 <div class="schema-usage" data-include="schema/prov.xsd" data-oninclude="insertSchema_wasGeneratedBy"></div>
-<pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Generation.xml" data-oninclude="formatExample"></pre>
+<!-- <pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Generation.xml" data-oninclude="formatExample"></pre> -->
 </section> <!-- end term-Generation -->
 
 <section id="term-Usage">
@@ -731,7 +731,7 @@
 <div class="glossary-ref" data-ref="glossary-usage"></div>
 <div class="schema-type" data-name="prov:Usage" data-include="schema/prov.xsd" data-oninclude="insertSchema_Usage"></div>
 <div class="schema-usage" data-include="schema/prov.xsd" data-oninclude="insertSchema_used"></div>
-<pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Usage.xml" data-oninclude="formatExample"></pre>
+<!-- <pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Usage.xml" data-oninclude="formatExample"></pre> -->
 </section> <!-- end term-Usage -->
 
 <section id="term-Communication">
@@ -739,7 +739,7 @@
 <div class="glossary-ref" data-ref="glossary-communication"></div>
 <div class="schema-type" data-name="prov:Communication" data-include="schema/prov.xsd" data-oninclude="insertSchema_Communication"></div>
 <div class="schema-usage" data-include="schema/prov.xsd" data-oninclude="insertSchema_wasInformedBy"></div>
-<pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Communication.xml" data-oninclude="formatExample"></pre>
+<!-- <pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Communication.xml" data-oninclude="formatExample"></pre> -->
 </section> <!-- end term-Communication -->
 
 <section id="term-Start">
@@ -747,7 +747,7 @@
 <div class="glossary-ref" data-ref="glossary-start"></div>
 <div class="schema-type" data-name="prov:Start" data-include="schema/prov.xsd" data-oninclude="insertSchema_Start"></div>
 <div class="schema-usage" data-include="schema/prov.xsd" data-oninclude="insertSchema_wasStartedBy"></div>
-<pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Start.xml" data-oninclude="formatExample"></pre>
+<!-- <pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Start.xml" data-oninclude="formatExample"></pre> -->
 </section> <!-- end term-Start -->
 
 <section id="term-End">
@@ -755,7 +755,7 @@
 <div class="glossary-ref" data-ref="glossary-end"></div>
 <div class="schema-type" data-name="prov:End" data-include="schema/prov.xsd" data-oninclude="insertSchema_End"></div>
 <div class="schema-usage" data-include="schema/prov.xsd" data-oninclude="insertSchema_wasEndedBy"></div>
-<pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Entity.xml" data-oninclude="formatExample"></pre>
+<!-- <pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Entity.xml" data-oninclude="formatExample"></pre> -->
 </section> <!-- end term-End -->
 
 <section id="term-Invalidation">
@@ -763,7 +763,7 @@
 <div class="glossary-ref" data-ref="glossary-invalidation"></div>
 <div class="schema-type" data-name="prov:Invalidation" data-include="schema/prov.xsd" data-oninclude="insertSchema_Invalidation"></div>
 <div class="schema-usage" data-include="schema/prov.xsd" data-oninclude="insertSchema_wasInvalidatedBy"></div>
-<pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Invalidation.xml" data-oninclude="formatExample"></pre>
+<!-- <pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Invalidation.xml" data-oninclude="formatExample"></pre> -->
 </section> <!-- end term-Invalidation -->
 
 </section> <!-- end component1 -->
@@ -778,25 +778,25 @@
 <div class="glossary-ref" data-ref="glossary-derivation"></div>
 <div class="schema-type" data-name="prov:Derivation" data-include="schema/prov.xsd" data-oninclude="insertSchema_Derivation"></div>
 <div class="schema-usage" data-include="schema/prov.xsd" data-oninclude="insertSchema_wasDerivedFrom"></div>
-<pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Derivation1.xml" data-oninclude="formatExample"></pre>
+<!-- <pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Derivation1.xml" data-oninclude="formatExample"></pre> -->
 </section> <!-- end term-Derivation -->
 
 <section id="term-Revision">
 <h3>Revision</h3>
 <div class="glossary-ref" data-ref="glossary-revision"></div>
-<pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Revision.xml" data-oninclude="formatExample"></pre>
+<!-- <pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Revision.xml" data-oninclude="formatExample"></pre> -->
 </section>  <!-- end term-Revision -->
 
 <section id="term-Quotation">
 <h3>Quotation</h3>
 <div class="glossary-ref" data-ref="glossary-quotation"></div>
-<pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Quotation.xml" data-oninclude="formatExample"></pre>
+<!-- <pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Quotation.xml" data-oninclude="formatExample"></pre> -->
 </section>  <!-- end term-Quotation -->
 
 <section id="term-Primary-Source">
 <h3>Primary Source</h3>
 <div class="glossary-ref" data-ref="glossary-primary-source"></div>
-<pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/PrimarySource.xml" data-oninclude="formatExample"></pre>
+<!-- <pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/PrimarySource.xml" data-oninclude="formatExample"></pre> -->
 </section>  <!-- end term-Primary-Source -->
 
 </section>  <!-- end component2 -->
@@ -812,7 +812,7 @@
 <div class="glossary-ref" data-ref="glossary-agent"></div>
 <div class="schema-type" data-name="prov:Agent" data-include="schema/prov.xsd" data-oninclude="insertSchema_Agent"></div>
 <div class="schema-usage" data-include="schema/prov.xsd" data-oninclude="insertSchema_agent"></div>
-<pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Agent.xml" data-oninclude="formatExample"></pre>
+<!-- <pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Agent.xml" data-oninclude="formatExample"></pre> -->
 </section> <!-- end term-Agent -->
 
 <section id="term-Attribution">
@@ -820,7 +820,7 @@
 <div class="glossary-ref" data-ref="glossary-attribution"></div>
 <div class="schema-type" data-name="prov:Attribution" data-include="schema/prov.xsd" data-oninclude="insertSchema_Attribution"></div>
 <div class="schema-usage" data-include="schema/prov.xsd" data-oninclude="insertSchema_wasAttributedTo"></div>
-<pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Attribution.xml" data-oninclude="formatExample"></pre>
+<!-- <pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Attribution.xml" data-oninclude="formatExample"></pre> -->
 </section>  <!-- end term-Attribution -->
 
 <section id="term-Association">
@@ -828,7 +828,7 @@
 <div class="glossary-ref" data-ref="glossary-activityAssociation"></div>
 <div class="schema-type" data-name="prov:Association" data-include="schema/prov.xsd" data-oninclude="insertSchema_Association"></div>
 <div class="schema-usage" data-include="schema/prov.xsd" data-oninclude="insertSchema_wasAssociatedWith"></div>
-<pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Association.xml" data-oninclude="formatExample"></pre>
+<!-- <pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Association.xml" data-oninclude="formatExample"></pre> -->
 </section>  <!-- end term-Association -->
 
 <section id="term-Delegation">
@@ -836,7 +836,7 @@
 <div class="glossary-ref" data-ref="glossary-delegation"></div>
 <div class="schema-type" data-name="prov:Delegation" data-include="schema/prov.xsd" data-oninclude="insertSchema_Delegation"></div>
 <div class="schema-usage" data-include="schema/prov.xsd" data-oninclude="insertSchema_actedOnBehalfOf"></div>
-<pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Delegation.xml" data-oninclude="formatExample"></pre>
+<!-- <pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Delegation.xml" data-oninclude="formatExample"></pre> -->
 </section> <!-- end term-Delegation -->
 
 <section id="term-Influence">
@@ -844,7 +844,7 @@
 <div class="glossary-ref" data-ref="glossary-influence"></div>
 <div class="schema-type" data-name="prov:Influence" data-include="schema/prov.xsd" data-oninclude="insertSchema_Influence"></div>
 <div class="schema-usage" data-include="schema/prov.xsd" data-oninclude="insertSchema_wasInfluencedBy"></div>
-<pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Influence.xml" data-oninclude="formatExample"></pre>
+<!-- <pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Influence.xml" data-oninclude="formatExample"></pre> -->
 </section> <!-- end term-influence -->
 
 </section> <!-- end component3 -->
@@ -862,7 +862,7 @@
 <div class="glossary-ref" data-ref="glossary-specialization"></div>
 <div class="schema-type" data-name="prov:Specialization" data-include="schema/prov.xsd" data-oninclude="insertSchema_Specialization"></div>
 <div class="schema-usage" data-include="schema/prov.xsd" data-oninclude="insertSchema_specializationOf"></div>
-<pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Specialization.xml" data-oninclude="formatExample"></pre>
+<!-- <pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Specialization.xml" data-oninclude="formatExample"></pre> -->
 </section> <!-- end term-Specialization -->
 
 <section id="term-Alternate">
@@ -870,7 +870,7 @@
 <div class="glossary-ref" data-ref="glossary-alternate"></div>
 <div class="schema-type" data-name="prov:Alternate" data-include="schema/prov.xsd" data-oninclude="insertSchema_Alternate"></div>
 <div class="schema-usage" data-include="schema/prov.xsd" data-oninclude="insertSchema_alternateOf"></div>
-<pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Alternate_43.xml" data-oninclude="formatExample"></pre>
+<!-- <pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Alternate_43.xml" data-oninclude="formatExample"></pre> -->
 </section> <!-- end term-Alternate -->
 
 <section id="term-Mention">
@@ -878,7 +878,7 @@
 <div class="glossary-ref" data-ref="glossary-mention"></div>
 <div class="schema-type" data-name="prov:Mention" data-include="schema/prov.xsd" data-oninclude="insertSchema_Mention"></div>
 <div class="schema-usage" data-include="schema/prov.xsd" data-oninclude="insertSchema_mentionOf"></div>
-<pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Mention_45.xml" data-oninclude="formatExample"></pre>
+<!-- <pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Mention_45.xml" data-oninclude="formatExample"></pre> -->
 </section> <!-- end term-Mention -->
 
 </section> <!-- end component5 -->
@@ -892,15 +892,74 @@
 <section id="term-Collection">
 <h3>Collection</h3>
 <div class="glossary-ref" data-ref="glossary-collection"></div>
-<pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Collection.xml" data-oninclude="formatExample"></pre>
+<pre class="example">
+&lt;?xml version="1.0" encoding="UTF-8"?&gt;
+
+&lt;!-- based on PROV-DM's Example 47 from http://www.w3.org/TR/prov-dm/#example_47 --&gt;
+
+&lt;prov:document
+    xmlns:prov="http://www.w3.org/ns/prov#"
+    xmlns:ex="http://example.com/ns/ex#"&gt;
+
+  &lt;!-- c0 is an empty collection --&gt;
+  &lt;prov:entity prov:id="c0"&gt;
+    &lt;!-- prov:EmptyCollection denotes an empty collection. --&gt;
+    &lt;prov:type>prov:EmptyCollection&lt;/prov:type&gt;
+  &lt;/prov:entity&gt;
+
+  &lt;!-- c1 is a collection, with unknown content --&gt;
+  &lt;prov:entity prov:id="c1"&gt;
+    &lt;!-- prov:Collection denotes an entity of type Collection, i.e. an entity that can participate in relations amongst collections --&gt;
+    &lt;prov:type&gt;prov:Collection&lt;/prov:type&gt;
+  &lt;/prov:entity&gt;
+
+&lt;/prov:document&gt;
+</pre>
 </section>  <!-- end term-Collection -->
 
 <section id="term-Membership">
 <h3>Membership</h3>
 <div class="glossary-ref" data-ref="glossary-membership"></div>
-<div class="schema-type" data-name="prov:Membership" data-include="schema/prov.xsd" data-oninclude="insertSchema_Membership"></div>
-<div class="schema-usage" data-include="schema/prov.xsd" data-oninclude="insertSchema_hadMember"></div>
-<pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Membership.xml" data-oninclude="formatExample"></pre>
+<div class="schema-type">
+	<pre>
+&lt;xs:complexType name="Membership"&gt;
+  &lt;xs:sequence&gt;
+    &lt;xs:element name="collection"  type="prov:EntityRef"/&gt;
+    &lt;xs:element name="entity"      type="prov:EntityRef" maxOccurs="unbounded"/&gt;
+  &lt;/xs:sequence&gt;
+&lt;/xs:complexType&gt;
+</pre>
+</div>
+<div class="schema-usage">
+	<pre>
+&lt;xs:element xmlns:xs="http://www.w3.org/2001/XMLSchema" name="hadMember" type="prov:Membership"/&gt;
+	</pre>
+</div>
+<pre class="example">
+&lt;?xml version="1.0" encoding="UTF-8"?&gt;
+
+&lt;!-- based on Example 48 from http://www.w3.org/TR/prov-dm/#example_48 --&gt;
+
+&lt;prov:document
+    xmlns:prov="http://www.w3.org/ns/prov#"&gt;
+
+  &lt;prov:entity prov:id="e0"/&gt;
+  &lt;prov:entity prov:id="e1"/&gt;
+  &lt;prov:entity prov:id="e2"/&gt;
+
+  &lt;prov:entity prov:id="c"&gt;
+    &lt;prov:type&gt;prov:Collection&lt;/prov:type&gt;
+  &lt;/prov:entity&gt;
+
+  &lt;prov:hadMember&gt;
+    &lt;prov:collection prov:ref="c"/&gt;
+    &lt;prov:entity prov:ref="e0"/&gt;
+    &lt;prov:entity prov:ref="e1"/&gt;
+    &lt;prov:entity prov:ref="e2"/&gt;
+  &lt;/prov:hadMember>
+
+&lt;/prov:document&gt;
+</pre>
 </section>  <!-- end term-Membership -->
 
 </section>   <!-- end component6 -->
@@ -918,21 +977,21 @@
 <h4>Label</h4>
 <div class="glossary-ref" data-ref="glossary-label"></div>
 <div class="schema-usage" data-include="schema/prov.xsd" data-oninclude="insertSchema_label"></div>
-<pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Label.xml" data-oninclude="formatExample"></pre>
+<!-- <pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Label.xml" data-oninclude="formatExample"></pre> -->
 </section> <!-- end element-Label -->
 
 <section id="element-Location">
 <h4>Location</h4>
 <div class="glossary-ref" data-ref="glossary-location"></div>
 <div class="schema-usage" data-include="schema/prov.xsd" data-oninclude="insertSchema_location"></div>
-<pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Location.xml" data-oninclude="formatExample"></pre>
+<!-- <pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Location.xml" data-oninclude="formatExample"></pre> -->
 </section> <!-- end element-Location -->
 
 <section id="element-Role">
 <h4>Role</h4>
 <div class="glossary-ref" data-ref="glossary-role"></div>
 <div class="schema-usage" data-include="schema/prov.xsd" data-oninclude="insertSchema_role"></div>
-<pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Role.xml" data-oninclude="formatExample"></pre>
+<!-- <pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Role.xml" data-oninclude="formatExample"></pre> -->
 </section> <!-- end element-Role -->
 
 <section id="element-Type">
@@ -946,7 +1005,7 @@
 <h4>Value</h4>
 <div class="glossary-ref" data-ref="glossary-value-attribute"></div>
 <div class="schema-usage" data-include="schema/prov.xsd" data-oninclude="insertSchema_value"></div>
-<pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Value.xml" data-oninclude="formatExample"></pre>
+<!--<pre class="example" data-include="../examples/eg-40-xml-examples-by-term/xml/Value.xml" data-oninclude="formatExample"></pre>-->
 </section> <!-- end element-Value -->
 
 </section> <!-- end further-elements -->