|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.sun.enterprise.util.i18n.StringManagerBase
public class StringManagerBase
Implementation of a local string manager. Provides access to i18n messages for classes that need them.
One StringManagerBase per resource bundle name can be created and accessed by the getManager method call.
| Constructor Summary | |
|---|---|
protected |
StringManagerBase(String resourceBundleName,
ClassLoader classLoader)
Initializes the resource bundle. |
| Method Summary | |
|---|---|
String |
getString(String key)
Returns a localized string. |
String |
getString(String key,
Object arg1)
Returns a local string for the caller and format the arguments accordingly. |
String |
getString(String key,
Object[] args)
Returns a local string for the caller and format the arguments accordingly. |
String |
getString(String key,
Object arg1,
Object arg2)
Returns a local string for the caller and format the arguments accordingly. |
String |
getString(String key,
Object arg1,
Object arg2,
Object arg3)
Returns a local string for the caller and format the arguments accordingly. |
String |
getString(String key,
Object arg1,
Object arg2,
Object arg3,
Object arg4)
Returns a local string for the caller and format the arguments accordingly. |
static StringManagerBase |
getStringManager(String resourceBundleName,
ClassLoader classLoader)
Returns a local string manager for the given resourceBundle name. |
String |
getStringWithDefault(String key,
String defaultValue)
Returns a localized string. |
String |
getStringWithDefault(String key,
String defaultFormat,
Object[] arguments)
Returns a local string for the caller and format the arguments accordingly. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
protected StringManagerBase(String resourceBundleName,
ClassLoader classLoader)
resourceBundleName - name of the resource bundle| Method Detail |
|---|
public static StringManagerBase getStringManager(String resourceBundleName,
ClassLoader classLoader)
resourceBundleName - name of the resource bundle
public String getString(String key)
key - the name of the resource to fetch
public String getStringWithDefault(String key,
String defaultValue)
key - the name of the resource to fetchdefaultValue - the default return value if not found
public String getStringWithDefault(String key,
String defaultFormat,
Object[] arguments)
key - the key to the local format stringdefaultFormat - the default format if not found in the resourcesarguments - the set of arguments to provide to the formatter
public String getString(String key,
Object arg1)
key - the key to the local format stringarg1 - the one argument to be provided to the formatter
public String getString(String key,
Object arg1,
Object arg2)
key - the key to the local format stringarg1 - first argument to be provided to the formatterarg2 - second argument to be provided to the formatter
public String getString(String key,
Object arg1,
Object arg2,
Object arg3)
key - the key to the local format stringarg1 - first argument to be provided to the formatterarg2 - second argument to be provided to the formatterarg3 - third argument to be provided to the formatter
public String getString(String key,
Object arg1,
Object arg2,
Object arg3,
Object arg4)
key - the key to the local format stringarg1 - first argument to be provided to the formatterarg2 - second argument to be provided to the formatterarg3 - third argument to be provided to the formatterarg4 - fourth argument to be provided to the formatter
public String getString(String key,
Object[] args)
key - the key to the local format stringargs - the array of arguments to be provided to the formatter
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||