org.jaffa.rules.fieldvalidators
Class StringFieldValidator

java.lang.Object
  extended byorg.jaffa.rules.fieldvalidators.AbstractFieldValidator
      extended byorg.jaffa.rules.fieldvalidators.StringFieldValidator
All Implemented Interfaces:
IFieldValidator

public class StringFieldValidator
extends AbstractFieldValidator

This implementation of the IFieldValidator ensures that the field has a valid String value.


Constructor Summary
StringFieldValidator()
           
 
Method Summary
 String getCaseType()
          Getter for property caseType.
 Integer getLength()
          Getter for property length.
 Integer getMinLength()
          Getter for property minLength.
 String getPattern()
          Getter for property pattern.
 void setCaseType(String caseType)
          Setter for property caseType.
 void setLength(Integer length)
          Setter for property length.
 void setMinLength(Integer minLength)
          Setter for property minLength.
 void setPattern(String pattern)
          Setter for property pattern.
 void validate()
          The RulesEngine will invoke this method to perform the field validation.
 
Methods inherited from class org.jaffa.rules.fieldvalidators.AbstractFieldValidator
cleanup, getLabelToken, getUow, getValue, init, setLabelToken, setUow, setValue
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

StringFieldValidator

public StringFieldValidator()
Method Detail

getPattern

public String getPattern()
Getter for property pattern.

Returns:
Value of property pattern.

setPattern

public void setPattern(String pattern)
Setter for property pattern.

Parameters:
pattern - New value of property pattern.

getLength

public Integer getLength()
Getter for property length.

Returns:
Value of property length.

setLength

public void setLength(Integer length)
Setter for property length.

Parameters:
length - New value of property length.

getCaseType

public String getCaseType()
Getter for property caseType.

Returns:
Value of property caseType.

setCaseType

public void setCaseType(String caseType)
Setter for property caseType.

Parameters:
caseType - New value of property caseType.

getMinLength

public Integer getMinLength()
Getter for property minLength.

Returns:
Value of property minLength.

setMinLength

public void setMinLength(Integer minLength)
Setter for property minLength.

Parameters:
minLength - New value of property minLength.

validate

public void validate()
              throws ValidationException,
                     FrameworkException
The RulesEngine will invoke this method to perform the field validation.

Specified by:
validate in interface IFieldValidator
Specified by:
validate in class AbstractFieldValidator
Throws:
ValidationException - if any validation rule fails.
FrameworkException - if any framework error occurs.


Copyright © 2002-2004 JAFFA Project.