W3C home > Mailing lists > Public > public-rdf-dawg-comments@w3.org > April 2007

Re: [OK?] Re: [SPARQL] i18n comment: Modification in description of langMatches operator

From: Addison Phillips <addison@inter-locale.com>
Date: Sun, 22 Apr 2007 14:32:57 +0100
Message-ID: <462B6409.6050308@inter-locale.com>
To: eric@w3.org
CC: fsasaki@w3.org, jjc@hpl.hp.com, public-rdf-dawg-comments@w3.org, public-i18n-core@w3.org


I sent comments that were apparently similar to Jeremy's to Felix 
privately. The following changes are better, but still not quite right 
in my opinion.

You have currently proposed:

Returns true if language-range (second argument) matches language-tag 
(first argument). language-range is a basic language range per Matching 
of Language Tags [RFC4647] section 2.1 and the matching scheme is basic 
filtering defined in [RFC4647] section 3.3.1. A language-range of "*" 
matches any non-empty language-tag string.

I observe:

1. Language matching in RFC 4647 is defined in terms of "language 
priority lists" made up of "language ranges". It may be useful to 
incorporate this concept into SPARQL query. If necessary, you may limit 
the list to a single range.

2. The special range "*" usually matches all language tags, including 
the empty tag. If it didn't, you would have the problem of not being 
able to select contents with no tag except explicitly. That is, to 
select everything, you'd need two queries: one for "*" and one for the 
empty tag. (Obviously, omitting the langmatches statement has the same 
effect, so your current text may be by design??)

3. You don't have a way of specifying the empty tag, or at least you 
don't enumerate it. The empty tag only matches itself. That is:

  FILTER langMatches( lang(?title), "")

only matches items with an xml:lang=""

You should call this fact out.

I would thus propose that you change your text to something like this:

Returns true if the language priority list in the second argument 
matches the language tag in the first argument according to the Basic 
Filter matching scheme in Matching of Language Tags [RFC 4647] Section 
3.3.1. The language range may consist of one or more basic language 
ranges (RFC 4647 Section 2.1) separated by commas or the empty string. 
The special range "*" matches all language tag values, including the 
empty value, while the empty string matches only items whose language 
tag is the empty string.


Addison Phillips
Editor, BCP 47 (RFC 4646, RFC 4647)

Internationalization is an architecture.
It is not a feature.
Received on Monday, 23 April 2007 03:35:08 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 20:52:08 UTC