RE: Change in definition of RDF literals

> -----Original Message-----
> From: ext Graham Klyne [mailto:gk@ninebynine.org]
> Sent: 22 May, 2003 14:32
> To: Stickler Patrick (NMP/Tampere); duerst@w3.org; jjc@hplb.hpl.hp.com
> Cc: w3c-rdfcore-wg@w3.org
> Subject: RE: Change in definition of RDF literals
> 
> 
> At 13:44 22/05/03 +0300, Patrick.Stickler@nokia.com wrote:
> > > At 11:25 22/05/03 +0300, Patrick.Stickler@nokia.com wrote:
> > > >(a) there can be entailments
> > > >that hold for XML literals due to canonicalization that do not
> > > >hold for plain literals and
> > >
> > > Since our recent decision to handle canonicalization in the
> > > parser [1][2],
> > > I don't think it's correct to say that C14N has any impact on
> > > entailment
> > > relationships between RDF graphs.
> >
> >It doesn't for XML literals. But if we treat plain literals
> >as XML literals, then some entailments that do not hold for
> >plain literals will then hold, since if the plain literals
> >are not canonicalized, they are not equal, but if they are
> >canonicalized (being treated as XML) then they could be.
> 
> I don't see the problem here:  a parser would apply C14N for 
> parseType="Literal", and not for other literals.  I.e. there 
> is still a 
> *syntactic* distinction, but could all be treated the same in 
> the graph.

That was not how I understood the suggestion. If all we have
are XML literals and typed literals, then I would expect
canonicalization to apply to all XML literals regardless.

Also, my concerns were about comparisons. Even if C14N was
only applied by the parser for parseType="Literal" cases,
equality would still be defined in terms of canonicalized
forms, and that would apply to all non-typed literals regardless 
of how they were serialized.

I.e.

   <foo>&lt;span xml:lang='en'&gt;blargh&lt;/span&gt;</foo>

should then equal and/or entail both

   <foo>&lt;span xml:lang="en"&gt;blargh&lt;/span&gt;</foo>

and

   <foo rdf:parseType="Literal">
      <span xml:lang="en">blargh</span>
   </foo>

Note the difference in single and double quotes around 'en',
which are subject to canonicalization.

If all we have are XML literals, then the above two forms
of expression canonicalize to the same value. 

Now, I myself could live with this. But it would require re-working
alot of the specs, and some very clear treatment in the Primer to
help folks understand how some of their previous simple strings
may in fact be canonicalized to something different and thus
equate with other strings that before were not considered
equal.

> >Martin had suggested that plain literals and XML literals
> >could be treated the same. I was simply pointing out that,
> >while we *could* do that, I think most users would not be
> >very happy with such a solution.
> 
> By "treated the same", I interpreted that to apply to the 
> graph, not the 
> RDF/XML syntax (see above).  So I'm still not seeing where a 
> problem would be.

See above.

Patrick

Received on Friday, 23 May 2003 03:48:01 UTC