public class NlsBundleHelper extends AbstractLoggableObject
NlsBundle interfaces.| Modifier and Type | Field and Description |
|---|---|
static NlsBundleHelper |
INSTANCE |
| Constructor and Description |
|---|
NlsBundleHelper()
The constructor.
|
| Modifier and Type | Method and Description |
|---|---|
static NlsBundleHelper |
getInstance() |
String |
getKey(Method method)
|
String |
getMessage(Method method)
|
ClassName |
getQualifiedLocation(Class<? extends NlsBundle> nlsBundleInterface)
This method gets the location of the
ResourceBundle base name for the given NlsBundle
interface. |
boolean |
isNlsBundleMethod(Method method,
boolean ignoreIllegalMethods)
|
ResourceBundle |
toResourceBundle(Class<? extends NlsBundle> bundleClass)
Converts the given
NlsBundle class to a ResourceBundle. |
getLoggerpublic static final NlsBundleHelper INSTANCE
getInstance()public static NlsBundleHelper getInstance()
public ClassName getQualifiedLocation(Class<? extends NlsBundle> nlsBundleInterface)
ResourceBundle base name for the given NlsBundle
interface.nlsBundleInterface - is the NlsBundle interface.ResourceBundle base name for the given NlsBundle interface.public String getKey(Method method)
method - is the Method to check.public String getMessage(Method method)
method - is the Method of a NlsBundle.bundle message or null if not present.public ResourceBundle toResourceBundle(Class<? extends NlsBundle> bundleClass)
NlsBundle class to a ResourceBundle.bundleClass - is the class reflecting a NlsBundle.ResourceBundle with the key/value pairs of the given bundleClass for
Locale.ROOT.public boolean isNlsBundleMethod(Method method, boolean ignoreIllegalMethods)
method - the Method to check.ignoreIllegalMethods - - true if illegal methods (non NlsBundleMethods other than those defined
by Object) should be ignored, false if they should cause an exception.true if the given Method is a legal NlsBundle method, false
otherwise (e.g. for toString()).Copyright © 2001–2015 mmm-Team. All rights reserved.