[oslc-core] xml in properties defined as String

Dave Steinberg davidms at ca.ibm.com
Tue May 15 15:13:10 EDT 2012


Hi Joe and Steve,

Neither of those assumptions are correct, from a pure RDF perspective.

1. It is true that the lexical space for XMLLiteral is a subset of all
strings, but the value space is disjoint from that lexical space and from
the value space of any XML schema datatype (see RDF Concepts: XML Content
within an RDF Graph). In other words, the objects of these two statements
(in N-Triples notation) have values that are not the same:

<http://www.example.com/item> <http://purl.org/dc/terms/description>
"<p>Text</p>"^^<http://www.w3.org/2001/XMLSchema#string>
<http://www.example.com/item> <http://purl.org/dc/terms/description>
"<p>Text</p>"^^<http://www.w3.org/1999/02/22-rdf-syntax-ns#XMLLiteral>

2. The parseType="attribute" construction in RDF/XML actually specifies
XMLLiteral as the type of the object (see RDF/XML Syntax Specification:
Production parseTypeLiteralPropertyElt). In other words, the following
RDF/XML snippet corresponds unambiguously to the latter statement above:

<rdf:Description rdf:about="http://www.example.com/item">
    <dcterms:description
rdf:parseType="Literal"><p>Text</p></dcterms:description>
</rdf:Description>

Cheers,
Dave

--
Dave Steinberg
IBM Rational Software
davidms at ca.ibm.com




From:	Steve K Speicher <sspeiche at us.ibm.com>
To:	Joe Ross <joeross at us.ibm.com>
Cc:	oslc-core at open-services.net
Date:	05/15/2012 02:05 PM
Subject:	Re: [oslc-core] xml in properties defined as String
Sent by:	oslc-core-bounces at open-services.net



Hi Joe,

Seems correct to me.

- Steve

> From: Joe Ross/Austin/IBM at IBMUS
> To: oslc-core at open-services.net,
> Date: 05/08/2012 08:51 PM
> Subject: [oslc-core] xml in properties defined as String
> Sent by: oslc-core-bounces at open-services.net
>
>
> I'm assuming that the space of XMLLiteral values is a subset of the set
of
> String values, so that all valid XMLLiteral values are also valid String
values.
> I'm also assuming that parseType attribute in RDF/XML is simply a
directive
> to the RDF/XML parser and can be used with String properties as well as
> XMLLiteral properties.
>
> So, for example if the property rr:name is defined as having the data
type
> String in an OSLC resource definition, the following would still be
legal:
> <rr:name parseType="Literal"><b>Title</b></rr:name>
>
> Are these assumptions correct?
>
> ================================================
> Joe Ross/Austin/IBM, joeross at us.ibm.com
> Tivoli Autonomic Computing & Component Technologies
> 512-286-8311, T/L
363-8311_______________________________________________
> Oslc-Core mailing list
> Oslc-Core at open-services.net
> http://open-services.net/mailman/listinfo/oslc-core_open-services.net


_______________________________________________
Oslc-Core mailing list
Oslc-Core at open-services.net
http://open-services.net/mailman/listinfo/oslc-core_open-services.net

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://open-services.net/pipermail/oslc-core_open-services.net/attachments/20120515/c4a53bf8/attachment-0003.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: graycol.gif
Type: image/gif
Size: 105 bytes
Desc: not available
URL: <http://open-services.net/pipermail/oslc-core_open-services.net/attachments/20120515/c4a53bf8/attachment.gif>


More information about the Oslc-Core mailing list