public class ResourceMessageInfo
extends java.lang.Object
implements java.lang.Cloneable
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
BUNDLENAME_FAILEDTEXT |
static java.lang.String |
BUNDLENAME_GENERICTEXT |
Constructor and Description |
---|
ResourceMessageInfo() |
ResourceMessageInfo(java.lang.String key) |
ResourceMessageInfo(java.lang.String resourceBundleName,
java.lang.String key) |
ResourceMessageInfo(java.lang.String resourceBundleName,
java.lang.String key,
java.util.List<java.lang.String> params) |
Modifier and Type | Method and Description |
---|---|
void |
addParameter(java.lang.String value) |
ResourceMessageInfo |
clone()
When we assign the instance of ResourceMessageInfo to an other object, we
should assign the cloned one.
|
java.lang.String |
getAltText() |
java.lang.String |
getKey() |
java.lang.String |
getMessage()
Attempt to get and convert the desired message out of the resource bundle and return
it as a String with all parameters substituted.
|
java.util.List<java.lang.String> |
getParams() |
java.lang.String |
getResourceBundleName() |
void |
reset() |
void |
setAltText(java.lang.String altText) |
void |
setAltText(java.lang.String altTextWithPlaceholder,
java.lang.String placeHolderDelim)
|
void |
setKey(java.lang.String key) |
void |
setParams(java.util.List<java.lang.String> params) |
void |
setParams(java.lang.String[] sparams) |
void |
setResourceBundleName(java.lang.String resourceBundleName) |
public static final java.lang.String BUNDLENAME_FAILEDTEXT
public static final java.lang.String BUNDLENAME_GENERICTEXT
public ResourceMessageInfo()
public ResourceMessageInfo(java.lang.String key)
public ResourceMessageInfo(java.lang.String resourceBundleName, java.lang.String key)
public ResourceMessageInfo(java.lang.String resourceBundleName, java.lang.String key, java.util.List<java.lang.String> params)
public void reset()
public java.lang.String getResourceBundleName()
public void setResourceBundleName(java.lang.String resourceBundleName)
public java.lang.String getKey()
public void setKey(java.lang.String key)
public java.util.List<java.lang.String> getParams()
public void setParams(java.util.List<java.lang.String> params)
public void setParams(java.lang.String[] sparams)
public void addParameter(java.lang.String value)
public java.lang.String getAltText()
public void setAltText(java.lang.String altText)
public void setAltText(java.lang.String altTextWithPlaceholder, java.lang.String placeHolderDelim)
params
must be set before calling this method.params
will contain the values to replace the placeholders in alternative text.altTextWithPlaceholder
- String, text with placeholder as %1%, %2% etc.placeHolderDelim
- String, such as %, used to replace placeholder by real parameter value.params
public java.lang.String getMessage()
public ResourceMessageInfo clone()
clone
in class java.lang.Object
Copyright © SAS Institute. All Rights Reserved.