com.ca.jcs.validator.meta
Class PropertyStateValidator

java.lang.Object
  extended by com.ca.jcs.cfg.Vetoable
      extended by com.ca.jcs.validator.meta.PropertyStateValidator
All Implemented Interfaces:
AttributeValidator

public abstract class PropertyStateValidator
extends Vetoable
implements AttributeValidator

Implemented by property validators that also optionally require access to an object's current attribute values in their checking.


Constructor Summary
PropertyStateValidator()
           
 
Method Summary
abstract  ErrorMessages validate(Attribute attr)
          Create/add case.
abstract  ErrorMessages validate(ModificationItem modItem, AttributesProxy currAttributes)
          Update/modify case.
 
Methods inherited from class com.ca.jcs.cfg.Vetoable
isVetoed, setVetoed
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PropertyStateValidator

public PropertyStateValidator()
Method Detail

validate

public abstract ErrorMessages validate(Attribute attr)
Create/add case.

Specified by:
validate in interface AttributeValidator
Parameters:
attr - Attribute whose values are to be validated.
Returns:
Null if all value have desired format, and otherwise one or more error messages where only their msgFormatId field needs to be set.

validate

public abstract ErrorMessages validate(ModificationItem modItem,
                                       AttributesProxy currAttributes)
Update/modify case.

Parameters:
modItem - Item being changed.
currAttributes - Provides lazy access to object's current attribute values, if required.
Returns:
Null on success, otherwise details of validation failures.


Created 2011-07-14 13:27 EST