|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.pf.nls.ResourceBundleTextProvider
public class ResourceBundleTextProvider
This is a simple wrapper around a resource bundle to give it the same interface ITextProvider as available for a TextContainer.
Constructor Summary | |
---|---|
ResourceBundleTextProvider(ResourceBundle bundle)
Initialize the new instance with default values. |
Method Summary | |
---|---|
boolean |
containsNothing()
Returns true if this text provider holds no text and also its default text provider contains nothing. |
Locale |
getLocale()
Returns the locale the underlying resource bundle was created |
Locale[] |
getLocales()
Returns the locales for which this text provider has text |
ResourceBundle |
getResourceBundle()
Returns the wrapped resource bundle |
String |
getText(String key)
Returns the text associated with the given key or null if the key cannot be found. |
void |
setResourceBundle(ResourceBundle newValue)
Set the wrapped resource bundle |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ResourceBundleTextProvider(ResourceBundle bundle)
Method Detail |
---|
public String getText(String key)
getText
in interface ITextProvider
key
- The identifier for the textpublic boolean containsNothing()
containsNothing
in interface IExtendedTextProvider
public Locale[] getLocales()
getLocales
in interface IExtendedTextProvider
public Locale getLocale()
public ResourceBundle getResourceBundle()
public void setResourceBundle(ResourceBundle newValue)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |