|
Oracle Fusion Middleware extensions for Logging and Diagnostics 11g Release 1 (11.1.2) E22565-02 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object oracle.apps.fnd.appltest.diagfwk.common.DiagBaseFactory oracle.apps.fnd.appltest.diagfwk.engine.provider.nls.NLSProvider
public abstract class NLSProvider
Provides APIs for performing NLS related tasks such as getting the current Locale and translating a message given the nls bundle name, nls message key and token name values.
Nested Class Summary | |
---|---|
static class |
NLSProvider.BundleType
Enumeration representing the various formats |
Nested classes/interfaces inherited from interface oracle.apps.fnd.appltest.diagfwk.common.DiagConstants |
---|
DiagConstants.ExecutionMode, DiagConstants.Format, DiagConstants.LinkType, DiagConstants.Status |
Field Summary | |
---|---|
static java.lang.String |
DELIM_MSG_SVC_NLS_KEY
Delimitor for the Message Service related NLS Keys that is used to delimit app code from the message name |
static java.lang.String |
NLS_BUNDLE_DEFAULT
Default Bundle name |
static java.lang.String |
NLS_BUNDLE_JAVA_RES
Bundle name that represents the Java Resource Bundle |
static java.lang.String |
NLS_BUNDLE_MSG_SVC
Bundle name that represents the FND Message Service |
static java.lang.String |
NLS_BUNDLE_RES_REF
Bundle name that represents the LCM SDK Resource Refs |
static java.lang.String |
NLS_BUNDLE_XLIFF
Bundle name that represents the ADF Resource Bundle |
Constructor Summary | |
---|---|
NLSProvider()
|
Method Summary | |
---|---|
static void |
clean()
Cleans up any resources held by underlying NLSBundles during translaction activity. |
protected abstract void |
cleanup()
Cleans up any resources held by underlying NLSBundles during translaction activity. |
static java.util.Locale |
getCurrentLocale()
Gets the current locale based on user session. |
protected abstract java.util.Locale |
getLocale()
Gets the current locale based on user session. |
static NLSBundle |
getNLSBundle(java.lang.String pNlsBundleName)
Returns an instance of NLSBundle for the given bundle name that can be used to translate resources from that bundle. |
protected abstract NLSBundle |
getNLSBundleForName(java.lang.String pNlsBundle)
Returns an instance of NLSBundle for the given bundle name that can be used to translate resources from that bundle. |
protected static boolean |
isSubClass(java.lang.Class pClass,
java.lang.Class pSuperClass)
Checks if the given class is a subclass of the given super class |
static java.lang.String |
translate(java.lang.String pNlsBundle,
java.lang.String pNlsKey,
NameValueList pTokens,
java.lang.String pDefault)
Returns a translated String based on the current locale for the given nls key and token values from the specified nls bundle. |
Methods inherited from class oracle.apps.fnd.appltest.diagfwk.common.DiagBaseFactory |
---|
createClassLoader, loadClassFor |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String NLS_BUNDLE_MSG_SVC
public static final java.lang.String NLS_BUNDLE_XLIFF
public static final java.lang.String NLS_BUNDLE_JAVA_RES
public static final java.lang.String NLS_BUNDLE_RES_REF
public static final java.lang.String NLS_BUNDLE_DEFAULT
public static final java.lang.String DELIM_MSG_SVC_NLS_KEY
Constructor Detail |
---|
public NLSProvider()
Method Detail |
---|
protected abstract java.util.Locale getLocale()
protected abstract NLSBundle getNLSBundleForName(java.lang.String pNlsBundle)
pNlsBundle
- name of the NLS Bundle that contains translatable
messages
protected abstract void cleanup()
public static java.util.Locale getCurrentLocale()
public static NLSBundle getNLSBundle(java.lang.String pNlsBundleName)
pNlsBundleName
- name of the NLS Bundle that contains translatable
messages. The bundle name can be class names for instances of Java
ResourceBundle classes, or ResourceRef classes or a constant
FND_MSG_SERVICE in which case a NLSBundle for fetching translated messages
from the FND Message service is returned.
public static java.lang.String translate(java.lang.String pNlsBundle, java.lang.String pNlsKey, NameValueList pTokens, java.lang.String pDefault)
pNlsBundle
- NLS Bundle where the translated resource existspNlsKey
- Key for the nls messagepTokens
- token name values (if any) that should be substitued
during the translationpDefault
- default message to return in case translation fails.
public static void clean()
protected static boolean isSubClass(java.lang.Class pClass, java.lang.Class pSuperClass)
|
Oracle Fusion Middleware extensions for Logging and Diagnostics 11g Release 1 (11.1.2) E22565-02 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |