com.ibm.datapower.wamt
Class Messages

java.lang.Object
  extended by com.ibm.datapower.wamt.Messages

public class Messages
extends java.lang.Object

Class for accessing NLS (National Language Support) enabled messages in the IBM WebSphere Appliance Management Toolkit.


Field Summary
static java.lang.String BUNDLE_NAME
           
static java.lang.String COPYRIGHT_2009_2013
           
static java.lang.String NONMSG_BUNDLE_NAME
           
 
Method Summary
static java.lang.String getNonMsgString(java.lang.String key)
          Return a String from the non-message text bundle.
static java.lang.String getNonMsgString(java.lang.String key, java.util.Locale locale)
          Return a String from the non-message text bundle, based on a locale.
static java.lang.String getNonMsgString(java.lang.String key, java.util.Locale locale, java.lang.Object arg)
          Return a String from the non-message text bundle, based on a locale, with a single text parameter substituted.
static java.lang.String getNonMsgString(java.lang.String key, java.util.Locale locale, java.lang.Object[] args)
          Return a String from the non-message text bundle, based on a locale, with text parameters substituted.
static java.lang.String getNonMsgString(java.lang.String key, java.lang.Object arg)
          Return a String from the non-message text bundle, using the default locale, with a single text parameter substituted.
static java.lang.String getNonMsgString(java.lang.String key, java.lang.Object[] args)
          Return a String from the non-message text bundle, using the default locale, with text parameters substituted.
static java.lang.String getString(java.util.ResourceBundle bundle, java.lang.String key)
          Returns an String from a bundle.
static java.lang.String getString(java.lang.String key)
          Return a String from the message bundle.
static java.lang.String getString(java.lang.String key, java.util.Locale locale)
          Return a String from the message bundle, based on a locale.
static java.lang.String getString(java.lang.String key, java.util.Locale locale, java.lang.Object arg)
          Return a String from the message bundle, based on a locale, with a single message parameter substituted.
static java.lang.String getString(java.lang.String key, java.util.Locale locale, java.lang.Object[] args)
          Return a String from the message bundle, based on a locale, with message parameters substituted.
static java.lang.String getString(java.lang.String key, java.lang.Object arg)
          Return a String from the message bundle, using the default locale, with a single message parameter substituted.
static java.lang.String getString(java.lang.String key, java.lang.Object[] args)
          Return a String from the message bundle, using the default locale, with message parameters substituted.
static void setMessagePrefix(java.lang.String inPrefix)
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

COPYRIGHT_2009_2013

public static final java.lang.String COPYRIGHT_2009_2013
See Also:
Constant Field Values

BUNDLE_NAME

public static final java.lang.String BUNDLE_NAME
See Also:
Constant Field Values

NONMSG_BUNDLE_NAME

public static final java.lang.String NONMSG_BUNDLE_NAME
See Also:
Constant Field Values
Method Detail

setMessagePrefix

public static void setMessagePrefix(java.lang.String inPrefix)

getString

public static java.lang.String getString(java.util.ResourceBundle bundle,
                                         java.lang.String key)
Returns an String from a bundle.

Parameters:
bundle - The bundle to get the string from
key - The key used to access the string in the bundle.
Returns:
The string from the bundle, or error text if the key is not found in the bundle.

getString

public static java.lang.String getString(java.lang.String key)
Return a String from the message bundle.

Parameters:
key - The key used to access the string in the bundle.
Returns:
The string from the bundle, or error text if the key is not found in the bundle.

getString

public static java.lang.String getString(java.lang.String key,
                                         java.util.Locale locale)
Return a String from the message bundle, based on a locale.

Parameters:
key - The key used to access the string in the bundle.
locale - The locale for the string to be returned.
Returns:
The string from the bundle, or error text if the key is not found in the bundle.

getString

public static final java.lang.String getString(java.lang.String key,
                                               java.util.Locale locale,
                                               java.lang.Object[] args)
Return a String from the message bundle, based on a locale, with message parameters substituted.

Parameters:
key - The key used to access the string in the bundle.
locale - The locale for the string to be returned.
args - The array of parameters to be substituted in the message.
Returns:
The string from the bundle with the message parameters substituted, or error text if the key is not found in the bundle.

getString

public static final java.lang.String getString(java.lang.String key,
                                               java.lang.Object[] args)
Return a String from the message bundle, using the default locale, with message parameters substituted.

Parameters:
key - The key used to access the string in the bundle.
args - The array of parameters to be substituted in the message.
Returns:
The string from the bundle with the message parameters substituted, or error text if the key is not found in the bundle.

getString

public static final java.lang.String getString(java.lang.String key,
                                               java.util.Locale locale,
                                               java.lang.Object arg)
Return a String from the message bundle, based on a locale, with a single message parameter substituted.

Parameters:
key - The key used to access the string in the bundle.
locale - The locale for the string to be returned.
arg - The single parameter to be substituted in the message.
Returns:
The string from the bundle with the message parameter substituted, or error text if the key is not found in the bundle.

getString

public static final java.lang.String getString(java.lang.String key,
                                               java.lang.Object arg)
Return a String from the message bundle, using the default locale, with a single message parameter substituted.

Parameters:
key - The key used to access the string in the bundle.
arg - The single parameter to be substituted in the message.
Returns:
The string from the bundle with the message parameter substituted, or error text if the key is not found in the bundle.

getNonMsgString

public static java.lang.String getNonMsgString(java.lang.String key)
Return a String from the non-message text bundle.

Parameters:
key - The key used to access the string in the bundle.
Returns:
The string from the bundle, or error text if the key is not found in the bundle.

getNonMsgString

public static java.lang.String getNonMsgString(java.lang.String key,
                                               java.util.Locale locale)
Return a String from the non-message text bundle, based on a locale.

Parameters:
key - The key used to access the string in the bundle.
locale - The locale for the string to be returned.
Returns:
The string from the bundle, or error text if the key is not found in the bundle.

getNonMsgString

public static final java.lang.String getNonMsgString(java.lang.String key,
                                                     java.util.Locale locale,
                                                     java.lang.Object[] args)
Return a String from the non-message text bundle, based on a locale, with text parameters substituted.

Parameters:
key - The key used to access the string in the bundle.
locale - The locale for the string to be returned.
args - The array of parameters to be substituted in the text.
Returns:
The string from the bundle with the text parameters substituted, or error text if the key is not found in the bundle.

getNonMsgString

public static final java.lang.String getNonMsgString(java.lang.String key,
                                                     java.lang.Object[] args)
Return a String from the non-message text bundle, using the default locale, with text parameters substituted.

Parameters:
key - The key used to access the string in the bundle.
args - The array of parameters to be substituted in the text.
Returns:
The string from the bundle with the text parameters substituted, or error text if the key is not found in the bundle.

getNonMsgString

public static final java.lang.String getNonMsgString(java.lang.String key,
                                                     java.util.Locale locale,
                                                     java.lang.Object arg)
Return a String from the non-message text bundle, based on a locale, with a single text parameter substituted.

Parameters:
key - The key used to access the string in the bundle.
locale - The locale for the string to be returned.
arg - The single parameter to be substituted in the text.
Returns:
The string from the bundle with the text parameter substituted, or error text if the key is not found in the bundle.

getNonMsgString

public static final java.lang.String getNonMsgString(java.lang.String key,
                                                     java.lang.Object arg)
Return a String from the non-message text bundle, using the default locale, with a single text parameter substituted.

Parameters:
key - The key used to access the string in the bundle.
arg - The single parameter to be substituted in the text.
Returns:
The string from the bundle with the text parameter substituted, or error text if the key is not found in the bundle.


© Copyright IBM Corp. 2006, 2010 All Rights Reserved.