|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.apache.struts.action.ActionMessages
org.apache.struts.action.ActionErrors
A class that encapsulates the error messages being reported by
the validate() method of an ActionForm.
Validation errors are either global to the entire ActionForm
bean they are associated with, or they are specific to a particular
bean property (and, therefore, a particular input field on the corresponding
form).
Each individual error is described by an ActionMessage
object, which contains a message key (to be looked up in an appropriate
message resources database), and up to four placeholder arguments used for
parametric substitution in the resulting message.
IMPLEMENTATION NOTE - It is assumed that these objects are created and manipulated only within the context of a single thread. Therefore, no synchronization is required for access to internal collections.
| Nested Class Summary |
| Nested classes inherited from class org.apache.struts.action.ActionMessages |
ActionMessages.ActionMessageItem |
| Field Summary | |
static java.lang.String |
GLOBAL_ERROR
Deprecated. Use ActionMessages.GLOBAL_MESSAGE instead. This will be removed after Struts 1.2. |
| Fields inherited from class org.apache.struts.action.ActionMessages |
accessed, GLOBAL_MESSAGE, iCount, messages |
| Constructor Summary | |
ActionErrors()
Create an empty ActionErrors object. |
|
ActionErrors(ActionErrors messages)
Create an ActionErrors object initialized with the given
messages. |
|
| Method Summary | |
void |
add(java.lang.String property,
ActionError error)
Deprecated. Use add(String, ActionMessage) instead. This will be removed after Struts 1.2. |
| Methods inherited from class org.apache.struts.action.ActionMessages |
add, add, clear, get, get, isAccessed, isEmpty, properties, size, size, toString |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
public static final java.lang.String GLOBAL_ERROR
| Constructor Detail |
public ActionErrors()
ActionErrors object.
public ActionErrors(ActionErrors messages)
ActionErrors object initialized with the given
messages.
messages - The messages to be initially added to this object.
This parameter can be null.| Method Detail |
public void add(java.lang.String property,
ActionError error)
property - Property name (or ActionErrors.GLOBAL_ERROR)error - The error message to be added
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||