On Mon, Jun 20, 2011 at 12:32 PM, Henry Story <[email protected]>wrote:
>
> On 20 Jun 2011, at 12:15, Reto Bachmann-Gmuer wrote:
>
> > Currently the literal factory returns xsd:String-literals for strings
> (the
> > literal factory only produces typed literals). By contrast EasyGraph
> (which
> > is imported by default on the shell converts to Plain Literals as the
> > following Tests shows:
> >
> > @Test
> > def useStringAsObject {
> > val t = new TripleImpl(new UriRef(("http://example.org/subject
> ")),
> > new UriRef(("http://example.org/predicate")), "a value")
> > Assert.assertEquals(new PlainLiteralImpl("a value"), t.getObject)
> > }
> >
> > I think for strings that are not natural language it is better to use
> > xsd:String, so I suggest only to convert literals with a specified
> language
> > implicitly to plain literals and use xsd:String otherwise.
> >
> > Any other opinion on this?
>
> Is there a semantic difference between "hello" and "hello"^^xsd:string ?
>
> I think there is not, and I'd hope that in the RDF DBs all sss^^xsd:string
> get converted
> to pure sss strings . In the syntax I can see that there is a difference,
> in that if in rdfa someone
> puts the language tag somewhere, then, when someone writes "hello" it will
> be parsed as
> "hello"@en, which is different. But then that would be an issue for
> parsers.
>
> I suppose one should be consistent, but I am not sure which way one should
> be consistent in.
> I doubt we have very good reason either way, so whatever is chosen I'd flag
> it as arbitrary, until
> we have a good reason for why we think a choice is necessary.
>
> Henry
>
It seems things has been discussed in the now closed RDF WG ISSUE-12 [1].
The resolution seems to be to use "foo" as the preferred way (in concrete
syntaxes) to write "foo"^^xsd:String, but that the internal form should be
"foo"^^xsd:String. This seems to be consistent with Tsuy review of
CLEREZZA-304, the range of properties that have strings without language as
value should be xsd:String.
I don't know any RDF DB doing a replacement here.
I'll change the test and implementation and add this too the documentation.
Reto
1. http://www.w3.org/2011/rdf-wg/track/issues/12
>
>
> >
> > Cheers,
> > Reto
>
> Social Web Architect
> http://bblfish.net/
>
>