|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object
|
+--com.artima.place.info.LocalizableInfo
|
+--com.artima.place.info.Description
A localizable description.
| Constructor Summary | |
Description(java.util.Locale cachedLocale,
java.lang.String cachedDescription)
Constructs a new Description with passed cached
description for the passed locale, and no name key resource bundle
loader. |
|
Description(ResourceBundleLoader loader,
java.lang.String descriptionKey)
Constructs a new Description with passed resource bundle
loader, description key, and no cached description. |
|
Description(ResourceBundleLoader loader,
java.lang.String descriptionKey,
java.util.Locale cachedLocale,
java.lang.String cachedDescription)
Constructs a new Description with passed resource bundle
loader, description key, and cached description (for the passed
locale). |
|
| Method Summary | |
java.lang.Object |
clone()
Clones this Name. |
boolean |
equals(java.lang.Object o)
Compares this Description to the passed object for
equality. |
java.lang.String |
getDescription()
Returns a String description, suitable for presentation
to users, appropriate to the default locale. |
java.lang.String |
getDescription(java.util.Locale desiredLocale)
Returns a String description, suitable for presentation
to users, which represents the best-fit description for the specified
locale. |
int |
hashCode()
Returns a hash code for this object. |
void |
purge()
Purge away information about undesired locales. |
void |
purge(java.util.Locale preserveLocale)
Purge away information about all locales except the passed locale. |
| Methods inherited from class com.artima.place.info.LocalizableInfo |
clearCachedLocale, clearResourceBundleLoader, compareObjectsOrNull, getBestFitLocale, getBestFitLocale, getCachedLocale, getResourceBundleLoader, getSupportedLocales, hasCachedLocale, hasResourceBundleLoader, setCachedLocale, stripResourceBundleLoader, useCache |
| Methods inherited from class java.lang.Object |
finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public Description(ResourceBundleLoader loader,
java.lang.String descriptionKey)
Description with passed resource bundle
loader, description key, and no cached description.loader - the ResourceBundleLoader which can load
ResourceBundles for this Description.descriptionKey - the String key with which the
String resource can be retrieved from a
ResourceBundle provided by the
ResourceBundleLoader
public Description(ResourceBundleLoader loader,
java.lang.String descriptionKey,
java.util.Locale cachedLocale,
java.lang.String cachedDescription)
Description with passed resource bundle
loader, description key, and cached description (for the passed
locale).loader - the ResourceBundleLoader which can load
ResourceBundles for this Description.descriptionKey - the String key with which the
String resource can be retrieved from a
ResourceBundle provided by the
ResourceBundleLoadercachedLocale - the Locale of the description
passed as cachedDescription.cachedDescription - the description whose locale is passed as
cachedLocale that should be cached by this
Description.
public Description(java.util.Locale cachedLocale,
java.lang.String cachedDescription)
Description with passed cached
description for the passed locale, and no name key resource bundle
loader. (Because this Description info object contains no
resource bundle loader, it also requires no key with which to look up
a description resource in a resource bundle.cachedLocale - the Locale of the description
passed as cachedDescription.cachedDescription - the description, whose locale is passed as
cachedLocale that should be cached by this
Description.| Method Detail |
public java.lang.String getDescription()
String description, suitable for presentation
to users, appropriate to the default locale.String description, suitable for presentation
to users, appropriate to the default locale.MissingResourceException - if a codebase URL is found to be
unusable. (Because URLString enforces well-formedness
of all URLs used by this method, this exception probably indicates
the protocol was unknown.), or if a ResourceBundle is
not found at the expected codebasepublic java.lang.String getDescription(java.util.Locale desiredLocale)
String description, suitable for presentation
to users, which represents the best-fit description for the specified
locale.desiredLocale - the locale for which an appropriate description
is desired.String description, suitable for presentation
to users, appropriate to the passed desired locale.MissingResourceException - if a codebase URL is found to be
unusable. (Because URLString enforces well-formedness
of all URLs used by this method, this exception probably indicates
the protocol was unknown.), or if a ResourceBundle is
not found at the expected codebasepublic void purge()
purge in class LocalizableInfopublic void purge(java.util.Locale preserveLocale)
purge in class LocalizableInfopreserveLocale - a locale to preserve in this
Description.public boolean equals(java.lang.Object o)
Description to the passed object for
equality. To be semantically equal, the class of the passed object
must be Description, the passed object's cached
description must be semantically equal to this object's cached
description, the passed object's description key must be semantically
to this object's description key, and the equals method
of Description's superclass must return
true.equals in class LocalizableInfoAn - object to compare to this Descriptiontrue if this Description is
semantically equal to the passed Descriptionpublic int hashCode()
hashCode in class LocalizableInfopublic java.lang.Object clone()
Name.clone in class LocalizableInfo
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||