com.codestreet.messageforge
Class RFldConstraintDatetime

java.lang.Object
  extended bycom.codestreet.messageforge.RFldConstraintDatetime
All Implemented Interfaces:
RFldConstraint
Direct Known Subclasses:
RFldConstraintDatetimeEnum, RFldConstraintDatetimeMinMax

public abstract class RFldConstraintDatetime
extends java.lang.Object
implements RFldConstraint

Class to represent a constraint on a date message field.

Author:
Jawaid Hakim.

Constructor Summary
protected RFldConstraintDatetime()
          Ctor.
 
Method Summary
abstract  boolean isValid(java.util.Date data)
          Check if a date message field satisfies the constraint.
 boolean isValid(RFld fld)
          Check if a datetime message field satisfies the constraint.
 void validate(RFld fld)
          Check if a message field satisfies the constraint.
 void validate(RFld fld, java.util.Date val)
          Check if a value satisfies the constraint.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.codestreet.messageforge.RFldConstraint
errDesc
 

Constructor Detail

RFldConstraintDatetime

protected RFldConstraintDatetime()
Ctor.

Method Detail

validate

public void validate(RFld fld)
              throws FieldValidationException
Check if a message field satisfies the constraint.

Specified by:
validate in interface RFldConstraint
Parameters:
fld - Field to validate.
Throws:
FieldValidationException
See Also:
RFld

validate

public void validate(RFld fld,
                     java.util.Date val)
              throws FieldValidationException
Check if a value satisfies the constraint.

Parameters:
val - Value to validate.
Throws:
FieldValidationException

isValid

public boolean isValid(RFld fld)
Check if a datetime message field satisfies the constraint.

Specified by:
isValid in interface RFldConstraint
Parameters:
fld - Field to validate.
Returns:
true if the field satisfied the constraint. Otherwise, false is returned.
See Also:
RFld

isValid

public abstract boolean isValid(java.util.Date data)
Check if a date message field satisfies the constraint.

Parameters:
data - Data to validate.
Returns:
true if the data satisfied the constraint. Otherwise, false is returned.


Copyright © 2003-2006 CodeStreet. All Rights Reserved.