|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.struts.action.ActionMessage
public class ActionMessage
An encapsulation of an individual message returned by the
validate method of an ActionForm, consisting of a
message key (to be used to look up message text in an appropriate message
resources database) plus up to four placeholder objects that can be used
for parametric replacement in the message text.
| Field Summary | |
|---|---|
protected java.lang.String |
key
The message key for this message. |
protected boolean |
resource
Indicates whether the key is taken to be as a bundle key [true] or literal value [false]. |
protected java.lang.Object[] |
values
The replacement values for this mesasge. |
| Constructor Summary | |
|---|---|
ActionMessage(java.lang.String key)
Construct an action message with no replacement values. |
|
ActionMessage(java.lang.String key,
boolean resource)
Construct an action message with the specified replacement values. |
|
ActionMessage(java.lang.String key,
java.lang.Object value0)
Construct an action message with the specified replacement values. |
|
ActionMessage(java.lang.String key,
java.lang.Object[] values)
Construct an action message with the specified replacement values. |
|
ActionMessage(java.lang.String key,
java.lang.Object value0,
java.lang.Object value1)
Construct an action message with the specified replacement values. |
|
ActionMessage(java.lang.String key,
java.lang.Object value0,
java.lang.Object value1,
java.lang.Object value2)
Construct an action message with the specified replacement values. |
|
ActionMessage(java.lang.String key,
java.lang.Object value0,
java.lang.Object value1,
java.lang.Object value2,
java.lang.Object value3)
Construct an action message with the specified replacement values. |
|
| Method Summary | |
|---|---|
java.lang.String |
getKey()
Get the message key for this message. |
java.lang.Object[] |
getValues()
Get the replacement values for this message. |
boolean |
isResource()
Indicate whether the key is taken to be as a bundle key [true] or literal value [false]. |
java.lang.String |
toString()
Returns a String in the format: key[value1, value2, etc]. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
protected java.lang.String key
The message key for this message.
protected java.lang.Object[] values
The replacement values for this mesasge.
protected boolean resource
Indicates whether the key is taken to be as a bundle key [true] or literal value [false].
| Constructor Detail |
|---|
public ActionMessage(java.lang.String key)
Construct an action message with no replacement values.
key - Message key for this message
public ActionMessage(java.lang.String key,
java.lang.Object value0)
Construct an action message with the specified replacement values.
key - Message key for this messagevalue0 - First replacement value
public ActionMessage(java.lang.String key,
java.lang.Object value0,
java.lang.Object value1)
Construct an action message with the specified replacement values.
key - Message key for this messagevalue0 - First replacement valuevalue1 - Second replacement value
public ActionMessage(java.lang.String key,
java.lang.Object value0,
java.lang.Object value1,
java.lang.Object value2)
Construct an action message with the specified replacement values.
key - Message key for this messagevalue0 - First replacement valuevalue1 - Second replacement valuevalue2 - Third replacement value
public ActionMessage(java.lang.String key,
java.lang.Object value0,
java.lang.Object value1,
java.lang.Object value2,
java.lang.Object value3)
Construct an action message with the specified replacement values.
key - Message key for this messagevalue0 - First replacement valuevalue1 - Second replacement valuevalue2 - Third replacement valuevalue3 - Fourth replacement value
public ActionMessage(java.lang.String key,
java.lang.Object[] values)
Construct an action message with the specified replacement values.
key - Message key for this messagevalues - Array of replacement values
public ActionMessage(java.lang.String key,
boolean resource)
Construct an action message with the specified replacement values.
key - Message key for this messageresource - Indicates whether the key is a bundle key or literal
value| Method Detail |
|---|
public java.lang.String getKey()
Get the message key for this message.
public java.lang.Object[] getValues()
Get the replacement values for this message.
public boolean isResource()
Indicate whether the key is taken to be as a bundle key [true] or literal value [false].
true if the key is a bundle key;
false otherwise.public java.lang.String toString()
Returns a String in the format: key[value1, value2, etc].
toString in class java.lang.ObjectObject.toString()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||