org.apache.commons.validator
Class ValidatorResult

java.lang.Object
  extended byorg.apache.commons.validator.ValidatorResult
All Implemented Interfaces:
java.io.Serializable

public class ValidatorResult
extends java.lang.Object
implements java.io.Serializable

This contains the results of a set of validation rules processed on a JavaBean.

See Also:
Serialized Form

Nested Class Summary
protected  class ValidatorResult.ResultStatus
          Contains the status of the validation.
 
Field Summary
protected  Field field
          Field being validated.
protected  java.util.Map hAction
          Map of results.
 
Constructor Summary
ValidatorResult(Field field)
          Constructs a ValidatorResult with the associated field being validated.
 
Method Summary
 void add(java.lang.String validatorName, boolean result)
          Add the result of a validator action.
 void add(java.lang.String validatorName, boolean result, java.lang.Object value)
          Add the result of a validator action.
 boolean containsAction(java.lang.String validatorName)
           
 java.util.Map getActionMap()
           
 Field getField()
          Returns the Field that was validated.
 boolean isValid(java.lang.String validatorName)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

hAction

protected java.util.Map hAction
Map of results. The key is the name of the ValidatorAction and the value is whether or not this field passed or not.


field

protected Field field
Field being validated. TODO This variable is not used. Need to investigate removing it.

Constructor Detail

ValidatorResult

public ValidatorResult(Field field)
Constructs a ValidatorResult with the associated field being validated.

Method Detail

add

public void add(java.lang.String validatorName,
                boolean result)
Add the result of a validator action.


add

public void add(java.lang.String validatorName,
                boolean result,
                java.lang.Object value)
Add the result of a validator action.


containsAction

public boolean containsAction(java.lang.String validatorName)

isValid

public boolean isValid(java.lang.String validatorName)

getActionMap

public java.util.Map getActionMap()

getField

public Field getField()
Returns the Field that was validated.



Copyright (c) 2001-2004 Apache Software Foundation