wheel.components
Class Validations

java.lang.Object
  extended by wheel.components.Validations

public class Validations
extends java.lang.Object

Validation methods available by default in validation expressions.

Author:
Henri Frilund
See Also:
FormElement.validationRule(String, String)

Method Summary
static Validations getInstance()
           
 boolean isDouble(java.lang.String value)
          Returns true if value is a valid Double.
 boolean isEmail(java.lang.String value)
          Returns true if value is a valid email address.
 boolean isInt(java.lang.String value)
          Returns true if value is an integer.
 boolean required(java.lang.String value)
          Returns true if value is set.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

isInt

public boolean isInt(java.lang.String value)
Returns true if value is an integer.

Parameters:
value -
Returns:

required

public boolean required(java.lang.String value)
Returns true if value is set.

Parameters:
value -
Returns:

isDouble

public boolean isDouble(java.lang.String value)
Returns true if value is a valid Double.

Parameters:
value -
Returns:

isEmail

public boolean isEmail(java.lang.String value)
Returns true if value is a valid email address. Uses ".+@.+\.[a-z]+" as the regural expression.

Parameters:
value -
Returns:

getInstance

public static Validations getInstance()


Copyright © 2007-2008. All Rights Reserved.