key
- A resource tag. Currently, this parameter is ignored. The obvious
intent, however, is for getAvailableLocales() to return a list of only those
locales that contain a resource with the specified resource tag.
Before we implement this function this way, however, some thought should be
given to whether this is really the right thing to do. Because of the lookup
algorithm, a NumberFormat, for example, is "installed" for all locales. But if
we're trying to put up a list of NumberFormats to choose from, we may want to see
only a list of those locales that uniquely define a NumberFormat rather than
inheriting one from another locale. Thus, if fr and fr_CA uniquely define
NumberFormat data, but fr_BE doesn't, the user wouldn't see "French (Belgium)" in
the list and would go for "French (default)" instead. Of course, this means
"English (United States)" would not be in the list, since it is the default locale.
This might be okay, but might be confusing to some users.
In addition, the other functions that call getAvailableLocales() don't currently
all pass the right thing for "key," meaning that all of these functions should be
looked at before anything is done to this function.
We recommend that someone take some careful consideration of these issues before
modifying this function to pay attention to the "key" parameter. --rtg 1/26/98