org.apache.tapestry.valid
Class ValidationConstraint

java.lang.Object
  extended by org.apache.commons.lang.enum.Enum
      extended by org.apache.tapestry.valid.ValidationConstraint
All Implemented Interfaces:
Serializable, Comparable

public class ValidationConstraint
extends org.apache.commons.lang.enum.Enum

Defines an enumeration of different types of validation constraints that may be violated.

Version:
$Id: ValidationConstraint.java 243791 2004-02-19 17:38:13Z hlship $
Author:
Howard Lewis Ship
See Also:
Serialized Form

Field Summary
static ValidationConstraint CONSISTENCY
          Indicates a consistency error, usually between too different fields.
static ValidationConstraint DATE_FORMAT
          Indicates a general error in converting a String into a Date.
static ValidationConstraint DISALLOWED_PROTOCOL
          Indicates that the URL does not use one of the specified protocols
static ValidationConstraint EMAIL_FORMAT
          Indicates a general error in the format of a string that is to be interpreted as a email.
static ValidationConstraint MINIMUM_WIDTH
          Indicates that a non-null value was provided, but that (after removing leading and trailing whitespace), the value was not long enough.
static ValidationConstraint NUMBER_FORMAT
          Indicates a general error in the format of a string that is to be interpreted as a number.
static ValidationConstraint PATTERN_MISMATCH
          Indicates an error in a string that does not fulfill a pattern.
static ValidationConstraint REQUIRED
          Indicates that no value (or a value consisting only of white space) was provided for a field that requires a non-null value.
static ValidationConstraint TOO_LARGE
          Indicates that the value was too large (for a Date, too late).
static ValidationConstraint TOO_SMALL
          Indicates that the value was too small (for a Date, too early).
static ValidationConstraint URL_FORMAT
          Indicates that a URL is not of the correct format
 
Constructor Summary
protected ValidationConstraint(String name)
          Protected constructor, which allows new constraints to be created as subclasses.
 
Method Summary
 
Methods inherited from class org.apache.commons.lang.enum.Enum
compareTo, equals, getEnum, getEnumList, getEnumMap, getName, hashCode, iterator, readResolve, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

REQUIRED

public static final ValidationConstraint REQUIRED
Indicates that no value (or a value consisting only of white space) was provided for a field that requires a non-null value.


MINIMUM_WIDTH

public static final ValidationConstraint MINIMUM_WIDTH
Indicates that a non-null value was provided, but that (after removing leading and trailing whitespace), the value was not long enough.


DATE_FORMAT

public static final ValidationConstraint DATE_FORMAT
Indicates a general error in converting a String into a Date.


EMAIL_FORMAT

public static final ValidationConstraint EMAIL_FORMAT
Indicates a general error in the format of a string that is to be interpreted as a email.


NUMBER_FORMAT

public static final ValidationConstraint NUMBER_FORMAT
Indicates a general error in the format of a string that is to be interpreted as a number.


TOO_SMALL

public static final ValidationConstraint TOO_SMALL
Indicates that the value was too small (for a Date, too early).


TOO_LARGE

public static final ValidationConstraint TOO_LARGE
Indicates that the value was too large (for a Date, too late).


PATTERN_MISMATCH

public static final ValidationConstraint PATTERN_MISMATCH
Indicates an error in a string that does not fulfill a pattern.

Since:
3.0

CONSISTENCY

public static final ValidationConstraint CONSISTENCY
Indicates a consistency error, usually between too different fields.

Since:
3.0

URL_FORMAT

public static final ValidationConstraint URL_FORMAT
Indicates that a URL is not of the correct format

Since:
3.0

DISALLOWED_PROTOCOL

public static final ValidationConstraint DISALLOWED_PROTOCOL
Indicates that the URL does not use one of the specified protocols

Since:
3.0
Constructor Detail

ValidationConstraint

protected ValidationConstraint(String name)
Protected constructor, which allows new constraints to be created as subclasses.