public abstract class LocalizedNamesImplBase extends DefaultLocalizedNames implements Localizable
LocalizedNames
interface.likelyRegionCodes, namesMap, sortedRegionCodes
Constructor and Description |
---|
LocalizedNamesImplBase() |
Modifier and Type | Method and Description |
---|---|
String |
getRegionNameImpl(String regionCode) |
protected String[] |
loadLikelyRegionCodes()
Returns a possibly-empty array of country codes, ordered by the literate
population speaking this language.
|
protected void |
loadNameMap()
Initializes {
DefaultLocalizedNamesBase.namesMap to a map of region code (including
non-country codes) to localized names. |
protected void |
loadNameMapJava()
Load the code=>name map for use in pure Java.
|
protected abstract JavaScriptObject |
loadNameMapNative()
Load the code=>name map for use in JS.
|
protected boolean |
needsNameMap() |
protected static JavaScriptObject |
overrideMap(JavaScriptObject original,
JavaScriptObject override)
Add all entries in
override to the original map, replacing
any existing entries. |
loadSortedRegionCodes
getLikelyRegionCodes, getRegionName, getSortedRegionCodes
protected static final JavaScriptObject overrideMap(JavaScriptObject original, JavaScriptObject override)
override
to the original map, replacing
any existing entries. This is used by subclasses that need to slightly
alter the data used by the parent locale.public final String getRegionNameImpl(String regionCode)
getRegionNameImpl
in class DefaultLocalizedNamesBase
protected String[] loadLikelyRegionCodes()
DefaultLocalizedNamesBase
loadLikelyRegionCodes
in class DefaultLocalizedNamesBase
protected final void loadNameMap()
DefaultLocalizedNamesBase
DefaultLocalizedNamesBase.namesMap
to a map of region code (including
non-country codes) to localized names. Subclasses should generally call the
parent implementation and then change specific entries, though if most
entries are being changed they can just create their own map.loadNameMap
in class DefaultLocalizedNames
protected void loadNameMapJava()
protected abstract JavaScriptObject loadNameMapNative()
protected final boolean needsNameMap()
needsNameMap
in class DefaultLocalizedNamesBase
Copyright © 2018. All rights reserved.