OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.


Help: OASIS Mailing Lists Help | MarkMail Help

camp message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]

Subject: Sorting strings and URIs

Last week we discussed how to sort strings and URIs.
Here is my take on it:

1) For strings:
On the call we discussed using Unicode collation algorithm (http://www.unicode.org/reports/tr10/). I suggest we *not* use this. Two reasons: (a) we agreed to follow SCIM and SCIM does not use UCA, (b) more importantly, the provider is not going to know the locale for a generic string nor will it know the locale of the client. In the absence of locale information the only choice really is to sort it numerically by unicode value. This is what you get from java.lang.String methods. If a client has a need to sort it according to its locale it will have to do the work to make it so.

If there is a need for case-insensitive sorting we should add that as a separate parameter.

WRT 'null's they should be listed at the end for ascending order and at the beginning for descending order (this is what SQL does).

2) For URLs:
The simplest thing to do is to treat it as a string, with some pious advice for implementors to store URIs in their canonical form (as defined by RFC 3986) for consistency.



[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]