adding xml serialization examples based on examples from PROV-DM document and conforming to current prov.xsd schema
authorStephan Zednik <zednis@rpi.edu>
Mon, 20 Aug 2012 00:11:41 -0600
changeset 4363 b3c69c5b9632
parent 4362 e4bf5f6bf3e5
child 4364 ce36d29037f9
adding xml serialization examples based on examples from PROV-DM document and conforming to current prov.xsd schema
examples/eg-40-xml-examples-by-term/xml/Agent.xml
examples/eg-40-xml-examples-by-term/xml/Entity.xml
examples/eg-40-xml-examples-by-term/xml/Location.xml
examples/eg-40-xml-examples-by-term/xml/Organization.xml
examples/eg-40-xml-examples-by-term/xml/Role.xml
examples/eg-40-xml-examples-by-term/xml/SoftwareAgent.xml
examples/eg-40-xml-examples-by-term/xml/Usage.xml
--- a/examples/eg-40-xml-examples-by-term/xml/Agent.xml	Mon Aug 20 00:03:21 2012 -0600
+++ b/examples/eg-40-xml-examples-by-term/xml/Agent.xml	Mon Aug 20 00:11:41 2012 -0600
@@ -0,0 +1,10 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<prov:records xmlns:prov="http://www.w3.org/ns/prov#" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
+	<prov:agent prov:id="e1">
+		<prov:type>prov:Person</prov:type>
+		<!-- TODO Add ex namespace, example.xsd
+		<ex:name>Alice</ex:name>
+		<ex:employee>1234</ex:employee>
+		-->
+	</prov:agent>
+</prov:records>
--- a/examples/eg-40-xml-examples-by-term/xml/Entity.xml	Mon Aug 20 00:03:21 2012 -0600
+++ b/examples/eg-40-xml-examples-by-term/xml/Entity.xml	Mon Aug 20 00:11:41 2012 -0600
@@ -0,0 +1,10 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- based on Example 16 from http://www.w3.org/TR/prov-dm/#term-entity -->
+<prov:records xmlns:prov="http://www.w3.org/ns/prov#" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ex="http://example.com/ns/ex#" xmlns:tr="http://example.com/ns/tr#">
+	<prov:entity prov:id="tr:WD-prov-dm-20111215">
+		<prov:type>document</prov:type>
+		<!-- TODO: use inline schema for ex?
+		<ex:version>2</ex:version>
+		-->
+	</prov:entity>
+</prov:records>
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/examples/eg-40-xml-examples-by-term/xml/Location.xml	Mon Aug 20 00:11:41 2012 -0600
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- based on Example 50 from http://www.w3.org/TR/prov-dm/#example-location -->
+<prov:records xmlns:prov="http://www.w3.org/ns/prov#" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ex="http://example.com/ns/ex#">
+	<prov:entity prov:id="ex:MonaLisa">
+		<prov:type>StillImage</prov:type>
+		<prov:location>Le Louvre, Paris</prov:location>
+	</prov:entity>
+	<prov:entity prov:id="ex:cell">
+		<prov:location>(5,5)</prov:location>
+		<prov:value>10</prov:value>
+	</prov:entity>
+</prov:records>
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/examples/eg-40-xml-examples-by-term/xml/Organization.xml	Mon Aug 20 00:11:41 2012 -0600
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- based on Organization example from http://www.w3.org/TR/prov-dm/#section-example-c -->
+<prov:records xmlns:prov="http://www.w3.org/ns/prov#" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:w3="http://w3.org/">
+	<prov:agent prov:id="w3:Consortium">
+		<prov:type>prov:Organization</prov:type>
+	</prov:agent>
+</prov:records>
\ No newline at end of file
--- a/examples/eg-40-xml-examples-by-term/xml/Role.xml	Mon Aug 20 00:03:21 2012 -0600
+++ b/examples/eg-40-xml-examples-by-term/xml/Role.xml	Mon Aug 20 00:11:41 2012 -0600
@@ -1,12 +1,20 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<!-- based on Example 50 from http://www.w3.org/TR/prov-dm/#example-location -->
+<!-- based on Example 51 from http://www.w3.org/TR/prov-dm/#anexample-role -->
 <prov:records xmlns:prov="http://www.w3.org/ns/prov#" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ex="http://example.com/ns/ex#">
-	<prov:entity prov:id="ex:MonaLisa">
-		<prov:type>StillImage</prov:type>
-		<prov:location>Le Louvre, Paris</prov:location>
-	</prov:entity>
-	<prov:entity prov:id="ex:cell">
-		<prov:location>(5,5)</prov:location>
-		<prov:value>10</prov:value>
-	</prov:entity>
+	<prov:activity prov:id="ex:div01"/>
+	<prov:activity prov:id="a"/>
+	<prov:entity prov:id="ex:cell"/>
+	<prov:agent prov:id="ag"/>
+	<prov:dependencies>
+		<prov:wasAssociatedWith>
+			<prov:activity prov:ref="a"/>
+			<prov:agent prov:ref="ag"/>
+			<prov:role>operator</prov:role>
+		</prov:wasAssociatedWith>
+		<prov:used>
+			<prov:activity prov:ref="ex:div01"/>
+			<prov:entity prov:ref="ex:cell"/>
+			<prov:role>divisor</prov:role>
+		</prov:used>
+	</prov:dependencies>
 </prov:records>
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/examples/eg-40-xml-examples-by-term/xml/SoftwareAgent.xml	Mon Aug 20 00:11:41 2012 -0600
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--Based on example 52 from http://www.w3.org/TR/prov-dm/#term-attribute-type-->
+<prov:records xmlns:prov="http://www.w3.org/ns/prov#" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
+	<prov:agent prov:id="ag">
+		<prov:type>prov:SoftwareAgent</prov:type>
+	</prov:agent>
+</prov:records>
\ No newline at end of file
--- a/examples/eg-40-xml-examples-by-term/xml/Usage.xml	Mon Aug 20 00:03:21 2012 -0600
+++ b/examples/eg-40-xml-examples-by-term/xml/Usage.xml	Mon Aug 20 00:11:41 2012 -0600
@@ -18,4 +18,4 @@
 			<!--<ex:parameter>p2</ex:parameter>-->
 		</prov:used>
 	</prov:dependencies>
-</prov:records>
\ No newline at end of file
+</prov:records>