|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.sptci.echo2.Configuration
public class Configuration
A utility class that is used to load and retrieve the localised
configurable properties for UI components. This class needs
an active ApplicationInstance to be properly
initialised.
Copyright 2006 Sans Pareil Technologies, Inc.
| Field Summary | |
|---|---|
private static String |
BUNDLE_NAME
The name of the resource bundle to load. |
private static Logger |
logger
The logger used to log errors. |
private static HashMap<Locale,ResourceBundle> |
resource
The resource bundle that represents the appropriate properties file. |
| Constructor Summary | |
|---|---|
private |
Configuration()
Cannot be instantiated. |
| Method Summary | |
|---|---|
private static ResourceBundle |
fetchResourceBundle()
Fetch the appropriate ResourceBundle based upon the
Locale from resource. |
static int |
getInt(Object source,
String key)
Returns configured integer value for the key for the specified source object. |
static int |
getInt(String key)
Returns configured integer value for the key. |
static String |
getString(Object source,
String key)
Returns localised configured text for the key for the specified source object. |
static String |
getString(String key)
Returns localised configured text for the key. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
private static final String BUNDLE_NAME
private static final Logger logger
private static HashMap<Locale,ResourceBundle> resource
| Constructor Detail |
|---|
private Configuration()
| Method Detail |
|---|
public static final String getString(Object source,
String key)
source - The object for which the localised text is to be
retrieved.key - The key of the text to be returned
getString( String )public static final String getString(String key)
key - The key of the text to be returned
public static final int getInt(Object source,
String key)
source - The object whose configured localised value is
to be retrieved.key - The key of the integer value to be returned
getInt( String )public static final int getInt(String key)
key - The key of the integer value to be returned
private static final ResourceBundle fetchResourceBundle()
ResourceBundle based upon the
Locale from resource.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||