|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.mentawai.rule.BasicRule
org.mentawai.rule.DoubleRule
public class DoubleRule
A rule to validate doubles. You can also specify min and max values.
| Constructor Summary | |
|---|---|
DoubleRule()
Default constructor. |
|
DoubleRule(double min)
Creates a IntegerRule with a min value. |
|
DoubleRule(double min,
double max)
Creates a IntegerRule with a min and max values. |
|
| Method Summary | |
|---|---|
boolean |
check(String value)
Do the check. |
static DoubleRule |
getInstance()
|
static DoubleRule |
getInstance(double min)
Gets the instance. |
static DoubleRule |
getInstance(int min,
int max)
Gets the instance. |
Map<String,String> |
getTokens()
Returns a map with tokens that can be used in the error messages. |
| Methods inherited from class org.mentawai.rule.BasicRule |
|---|
check |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public DoubleRule()
public DoubleRule(double min)
min - The minimum value for the integer.
public DoubleRule(double min,
double max)
min - The minium value for the integer.max - The maximum value for the integer.| Method Detail |
|---|
public static DoubleRule getInstance()
public static DoubleRule getInstance(double min)
min - double
public static DoubleRule getInstance(int min,
int max)
min - doublemax - double
public Map<String,String> getTokens()
Rule
getTokens in interface RulegetTokens in class BasicRulepublic boolean check(String value)
check in class BasicRulevalue - The value to validate.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||