Plain or simple literals have the datatype xsd:string
authorMarkus Lanthaler <mark_lanthaler@gmx.net>
Mon, 24 Sep 2012 19:56:27 +0200
changeset 874 7b9d80de3ce7
parent 873 09652a3bf053
child 875 2ee93c43b470
Plain or simple literals have the datatype xsd:string

According to RDF-Concepts (http://www.w3.org/TR/rdf11-concepts/#dfn-simple-literal):

"Concrete syntaxes may support simple literals, consisting of only a lexical form without any datatype IRI or language tag. Simple literals only exist in concrete syntaxes, and are treated as syntactic sugar for abstract syntax literals with the datatype IRI http://www.w3.org/2001/XMLSchema#string."

Since the conversion to RDF is not targeted to a specific serialization format, all plain literals should be typed accordingly.
test-suite/tests/toRdf-0001-out.nq
test-suite/tests/toRdf-0002-out.nq
test-suite/tests/toRdf-0008-out.nq
test-suite/tests/toRdf-0009-out.nq
test-suite/tests/toRdf-0010-out.nq
test-suite/tests/toRdf-0011-out.nq
test-suite/tests/toRdf-0012-out.nq
test-suite/tests/toRdf-0014-out.nq
test-suite/tests/toRdf-0015-out.nq
test-suite/tests/toRdf-0025-out.nq
test-suite/tests/toRdf-0028-out.nq
test-suite/tests/toRdf-0029-out.nq
test-suite/tests/toRdf-0030-out.nq
--- a/test-suite/tests/toRdf-0001-out.nq	Mon Sep 24 19:52:19 2012 +0200
+++ b/test-suite/tests/toRdf-0001-out.nq	Mon Sep 24 19:56:27 2012 +0200
@@ -1,1 +1,1 @@
-<http://greggkellogg.net/foaf#me> <http://xmlns.com/foaf/0.1/name> "Gregg Kellogg" .
+<http://greggkellogg.net/foaf#me> <http://xmlns.com/foaf/0.1/name> "Gregg Kellogg"^^<http://www.w3.org/2001/XMLSchema#string> .
--- a/test-suite/tests/toRdf-0002-out.nq	Mon Sep 24 19:52:19 2012 +0200
+++ b/test-suite/tests/toRdf-0002-out.nq	Mon Sep 24 19:56:27 2012 +0200
@@ -1,1 +1,1 @@
-<http://greggkellogg.net/foaf#me> <http://xmlns.com/foaf/0.1/name> "Gregg Kellogg" .
+<http://greggkellogg.net/foaf#me> <http://xmlns.com/foaf/0.1/name> "Gregg Kellogg"^^<http://www.w3.org/2001/XMLSchema#string> .
--- a/test-suite/tests/toRdf-0008-out.nq	Mon Sep 24 19:52:19 2012 +0200
+++ b/test-suite/tests/toRdf-0008-out.nq	Mon Sep 24 19:56:27 2012 +0200
@@ -1,1 +1,1 @@
-_:t0 <http://example.com/default#foo> "bar" .
+_:t0 <http://example.com/default#foo> "bar"^^<http://www.w3.org/2001/XMLSchema#string> .
--- a/test-suite/tests/toRdf-0009-out.nq	Mon Sep 24 19:52:19 2012 +0200
+++ b/test-suite/tests/toRdf-0009-out.nq	Mon Sep 24 19:56:27 2012 +0200
@@ -1,1 +1,1 @@
-_:t0 <http://example.com/default#> "bar" .
+_:t0 <http://example.com/default#> "bar"^^<http://www.w3.org/2001/XMLSchema#string> .
--- a/test-suite/tests/toRdf-0010-out.nq	Mon Sep 24 19:52:19 2012 +0200
+++ b/test-suite/tests/toRdf-0010-out.nq	Mon Sep 24 19:56:27 2012 +0200
@@ -1,2 +1,2 @@
 <http://greggkellogg.net/foaf#me> <http://xmlns.com/foaf/0.1/knows> <http://manu.sporny.org/#me> .
-<http://manu.sporny.org/#me> <http://xmlns.com/foaf/0.1/name> "Manu Sporny" .
+<http://manu.sporny.org/#me> <http://xmlns.com/foaf/0.1/name> "Manu Sporny"^^<http://www.w3.org/2001/XMLSchema#string> .
--- a/test-suite/tests/toRdf-0011-out.nq	Mon Sep 24 19:52:19 2012 +0200
+++ b/test-suite/tests/toRdf-0011-out.nq	Mon Sep 24 19:56:27 2012 +0200
@@ -1,2 +1,2 @@
 <http://greggkellogg.net/foaf#me> <http://xmlns.com/foaf/0.1/knows> _:t0 .
-_:t0 <http://xmlns.com/foaf/0.1/name> "Dave Longley" .
+_:t0 <http://xmlns.com/foaf/0.1/name> "Dave Longley"^^<http://www.w3.org/2001/XMLSchema#string> .
--- a/test-suite/tests/toRdf-0012-out.nq	Mon Sep 24 19:52:19 2012 +0200
+++ b/test-suite/tests/toRdf-0012-out.nq	Mon Sep 24 19:56:27 2012 +0200
@@ -1,2 +1,2 @@
-<http://greggkellogg.net/foaf#me> <http://xmlns.com/foaf/0.1/knows> "Manu Sporny" .
-<http://greggkellogg.net/foaf#me> <http://xmlns.com/foaf/0.1/knows> "Dave Longley" .
+<http://greggkellogg.net/foaf#me> <http://xmlns.com/foaf/0.1/knows> "Manu Sporny"^^<http://www.w3.org/2001/XMLSchema#string> .
+<http://greggkellogg.net/foaf#me> <http://xmlns.com/foaf/0.1/knows> "Dave Longley"^^<http://www.w3.org/2001/XMLSchema#string> .
--- a/test-suite/tests/toRdf-0014-out.nq	Mon Sep 24 19:52:19 2012 +0200
+++ b/test-suite/tests/toRdf-0014-out.nq	Mon Sep 24 19:56:27 2012 +0200
@@ -1,3 +1,3 @@
 <http://greggkellogg.net/foaf#me> <http://xmlns.com/foaf/0.1/knows> _:t0 .
-_:t0 <http://www.w3.org/1999/02/22-rdf-syntax-ns#first> "Manu Sporny" .
+_:t0 <http://www.w3.org/1999/02/22-rdf-syntax-ns#first> "Manu Sporny"^^<http://www.w3.org/2001/XMLSchema#string> .
 _:t0 <http://www.w3.org/1999/02/22-rdf-syntax-ns#rest> <http://www.w3.org/1999/02/22-rdf-syntax-ns#nil> .
--- a/test-suite/tests/toRdf-0015-out.nq	Mon Sep 24 19:52:19 2012 +0200
+++ b/test-suite/tests/toRdf-0015-out.nq	Mon Sep 24 19:56:27 2012 +0200
@@ -1,5 +1,5 @@
 <http://greggkellogg.net/foaf#me> <http://xmlns.com/foaf/0.1/knows> _:t0 .
-_:t0 <http://www.w3.org/1999/02/22-rdf-syntax-ns#first> "Manu Sporny" .
+_:t0 <http://www.w3.org/1999/02/22-rdf-syntax-ns#first> "Manu Sporny"^^<http://www.w3.org/2001/XMLSchema#string> .
 _:t0 <http://www.w3.org/1999/02/22-rdf-syntax-ns#rest> _:t1 .
-_:t1 <http://www.w3.org/1999/02/22-rdf-syntax-ns#first> "Dave Longley" .
+_:t1 <http://www.w3.org/1999/02/22-rdf-syntax-ns#first> "Dave Longley"^^<http://www.w3.org/2001/XMLSchema#string> .
 _:t1 <http://www.w3.org/1999/02/22-rdf-syntax-ns#rest> <http://www.w3.org/1999/02/22-rdf-syntax-ns#nil> .
--- a/test-suite/tests/toRdf-0025-out.nq	Mon Sep 24 19:52:19 2012 +0200
+++ b/test-suite/tests/toRdf-0025-out.nq	Mon Sep 24 19:56:27 2012 +0200
@@ -1,3 +1,3 @@
 <http://greggkellogg.net/foaf#me> <http://xmlns.com/foaf/0.1/knows> _:t0 .
-_:t0 <http://www.w3.org/1999/02/22-rdf-syntax-ns#first> "Manu Sporny" .
+_:t0 <http://www.w3.org/1999/02/22-rdf-syntax-ns#first> "Manu Sporny"^^<http://www.w3.org/2001/XMLSchema#string> .
 _:t0 <http://www.w3.org/1999/02/22-rdf-syntax-ns#rest> <http://www.w3.org/1999/02/22-rdf-syntax-ns#nil> .
--- a/test-suite/tests/toRdf-0028-out.nq	Mon Sep 24 19:52:19 2012 +0200
+++ b/test-suite/tests/toRdf-0028-out.nq	Mon Sep 24 19:56:27 2012 +0200
@@ -1,6 +1,6 @@
-<http://example.org/fact1> <http://purl.org/dc/terms/title> "Hello World!" <http://example.org/sig1> .
+<http://example.org/fact1> <http://purl.org/dc/terms/title> "Hello World!"^^<http://www.w3.org/2001/XMLSchema#string> <http://example.org/sig1> .
 <http://example.org/sig1> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.w3.org/1999/02/22-rdf-syntax-ns#Graph> .
 <http://example.org/sig1> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://purl.org/security#SignedGraph> .
 <http://example.org/sig1> <http://purl.org/dc/terms/created> "2011-09-23T20:21:34Z"^^<http://www.w3.org/2001/XMLSchema#dateTime> .
-<http://example.org/sig1> <http://purl.org/security#signatureValue> "OGQzNGVkMzVm4NTIyZTkZDYMmMzQzNmExMgoYzI43Q3ODIyOWM32NjI=" .
+<http://example.org/sig1> <http://purl.org/security#signatureValue> "OGQzNGVkMzVm4NTIyZTkZDYMmMzQzNmExMgoYzI43Q3ODIyOWM32NjI="^^<http://www.w3.org/2001/XMLSchema#string> .
 <http://example.org/sig1> <http://purl.org/security#signer> <http://payswarm.example.com/i/john/keys/5> .
--- a/test-suite/tests/toRdf-0029-out.nq	Mon Sep 24 19:52:19 2012 +0200
+++ b/test-suite/tests/toRdf-0029-out.nq	Mon Sep 24 19:56:27 2012 +0200
@@ -1,4 +1,4 @@
 <http://en.wikipedia.org/wiki/Berlin> <http://data.wikipedia.org/vocab#population> "3499879"^^<http://www.w3.org/2001/XMLSchema#integer> <http://data.wikipedia.org/snaks/BerlinFact> .
 <http://data.wikipedia.org/snaks/BerlinFact> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://data.wikipedia.org/vocab#Snak> <http://data.wikipedia.org/snaks/Assertions> .
-<http://data.wikipedia.org/snaks/BerlinFact> <http://data.wikipedia.org/vocab#assertedBy> "http://www.statistik-berlin-brandenburg.de/" <http://data.wikipedia.org/snaks/Assertions> .
+<http://data.wikipedia.org/snaks/BerlinFact> <http://data.wikipedia.org/vocab#assertedBy> "http://www.statistik-berlin-brandenburg.de/"^^<http://www.w3.org/2001/XMLSchema#string> <http://data.wikipedia.org/snaks/Assertions> .
 <http://data.wikipedia.org/snaks/Assertions> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://data.wikipedia.org/vocab#SnakSet> .
--- a/test-suite/tests/toRdf-0030-out.nq	Mon Sep 24 19:52:19 2012 +0200
+++ b/test-suite/tests/toRdf-0030-out.nq	Mon Sep 24 19:56:27 2012 +0200
@@ -1,7 +1,7 @@
 <http://manu.sporny.org/i/public> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <foaf:Person> <http://example.org/linked-data-graph> .
-<http://manu.sporny.org/i/public> <http://xmlns.com/foaf/0.1/knows> "http://greggkellogg.net/foaf#me" <http://example.org/linked-data-graph> .
-<http://manu.sporny.org/i/public> <http://xmlns.com/foaf/0.1/name> "Manu Sporny" <http://example.org/linked-data-graph> .
+<http://manu.sporny.org/i/public> <http://xmlns.com/foaf/0.1/knows> "http://greggkellogg.net/foaf#me"^^<http://www.w3.org/2001/XMLSchema#string> <http://example.org/linked-data-graph> .
+<http://manu.sporny.org/i/public> <http://xmlns.com/foaf/0.1/name> "Manu Sporny"^^<http://www.w3.org/2001/XMLSchema#string> <http://example.org/linked-data-graph> .
 <http://greggkellogg.net/foaf#me> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <foaf:Person> <http://example.org/linked-data-graph> .
-<http://greggkellogg.net/foaf#me> <http://xmlns.com/foaf/0.1/knows> "http://manu.sporny.org/i/public" <http://example.org/linked-data-graph> .
-<http://greggkellogg.net/foaf#me> <http://xmlns.com/foaf/0.1/name> "Gregg Kellogg" <http://example.org/linked-data-graph> .
+<http://greggkellogg.net/foaf#me> <http://xmlns.com/foaf/0.1/knows> "http://manu.sporny.org/i/public"^^<http://www.w3.org/2001/XMLSchema#string> <http://example.org/linked-data-graph> .
+<http://greggkellogg.net/foaf#me> <http://xmlns.com/foaf/0.1/name> "Gregg Kellogg"^^<http://www.w3.org/2001/XMLSchema#string> <http://example.org/linked-data-graph> .
 <http://example.org/linked-data-graph> <http://example.org/asOf> "2012-04-09"^^<http://www.w3.org/2001/XMLSchema#date> .