Top Description Fields Constructors Methods
com.sun.faces.application

public Class ApplicationResourceBundle

extends Object
Class Inheritance
Static Imports
com.sun.faces.util.Util.coalesce, .Util.getCurrentLoader

Contains an application level resource bundle name and its associated descriptions, if any.

Field Summary

Modifier and TypeField and Description
private final String
public static final String
private final Map<String, String>
private final Map<String, String>
private volatile Map<Locale, ResourceBundle>

Constructor Summary

AccessConstructor and Description
public
ApplicationResourceBundle(String
the base name of the ResourceBundle
baseName
,
Map<String, String>
any display names that were associated with the resource bundle definition in the configuration resource
displayNames
,
Map<String, String>
any descriptions that were associated with the resource bundle definition in the configuration resource
descriptions
)

Constructs a new ApplicationResourceBundle

Method Summary

Modifier and TypeMethod and Description
public String

Returns:

the base name of the ResourceBundle associated with this ApplicationResourceBundle instance
getBaseName
()

public String

Returns:

a text of a description element associated with the specified locale
getDescription
(Locale
a Locale
locale
)

public String

Returns:

a text of a display-name element associated with the specified locale
getDisplayName
(Locale
a Locale
locale
)

public ResourceBundle

Returns:

return the ResourceBundle associated with the specified locale
getResourceBundle
(Locale
a Locale
locale
)

private String

Returns:

localized text, if any
queryMap
(Locale
Locale if interest
locale
,
Map<String, String>
a map containing localized text keyed by Locale
map
)

Lookup and return the text for the specified Locale from within the specified Map.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

baseNameback to summary
private final String baseName
DEFAULT_KEYback to summary
public static final String DEFAULT_KEY
descriptionsback to summary
private final Map<String, String> descriptions
displayNamesback to summary
private final Map<String, String> displayNames
resourcesback to summary
private volatile Map<Locale, ResourceBundle> resources

Constructor Detail

ApplicationResourceBundleback to summary
public ApplicationResourceBundle(String baseName, Map<String, String> displayNames, Map<String, String> descriptions)

Constructs a new ApplicationResourceBundle

Parameters
baseName:String

the base name of the ResourceBundle

displayNames:Map<String, String>

any display names that were associated with the resource bundle definition in the configuration resource

descriptions:Map<String, String>

any descriptions that were associated with the resource bundle definition in the configuration resource

Method Detail

getBaseNameback to summary
public String getBaseName()
Returns:String

the base name of the ResourceBundle associated with this ApplicationResourceBundle instance

getDescriptionback to summary
public String getDescription(Locale locale)
Parameters
locale:Locale

a Locale

Returns:String

a text of a description element associated with the specified locale

getDisplayNameback to summary
public String getDisplayName(Locale locale)
Parameters
locale:Locale

a Locale

Returns:String

a text of a display-name element associated with the specified locale

getResourceBundleback to summary
public ResourceBundle getResourceBundle(Locale locale)
Parameters
locale:Locale

a Locale

Returns:ResourceBundle

return the ResourceBundle associated with the specified locale

queryMapback to summary
private String queryMap(Locale locale, Map<String, String> map)

Lookup and return the text for the specified Locale from within the specified Map.

Parameters
locale:Locale

Locale if interest

map:Map<String, String>

a map containing localized text keyed by Locale

Returns:String

localized text, if any