public static class Validators.NumericValidator extends Validators.StringTrimmingValidator
CLASS_VERSION| Constructor and Description | 
|---|
NumericValidator()
Create a new instance. 
 | 
NumericValidator(boolean pRequired)
Create a new instance. 
 | 
NumericValidator(java.lang.String pErrorCode)
Create a new instance. 
 | 
NumericValidator(java.lang.String pErrorCode,
                boolean pRequired)
Create a new instance. 
 | 
NumericValidator(java.lang.String pErrorCode,
                boolean pRequired,
                int pMaxLength)
Create a new instance. 
 | 
| Modifier and Type | Method and Description | 
|---|---|
java.lang.String | 
validateValue(java.lang.String pPropertyName,
             java.lang.Object pPropertyValue,
             ValidatorContext<?> pContext)
Validate (and possibly convert) the specified property value. 
 | 
shouldTrimgetMaxLength, setMaxLengthgetClassRequired, getRequiredOption, getRequiredPredicate, isRequired, keyMustBePresent, setClassRequired, setRequired, setRequiredOption, setRequiredPredicateassertAlphanumeric, assertBoolean, assertDateTime, assertDouble, assertInstanceOf, assertInteger, assertLong, assertNotBlankString, assertNotEmpty, assertNotEmpty, assertNotNull, assertNotNull, assertString, assertString, assertString, createInstance, getBeanPropertyValueForValidation, getErrorCode, getNameForClass, getPropertyNames, getPropertyValue, getPropertyValue, hasProperty, isDigits, isRequired, setErrorCode, setPropertyValue, validateBeanPropertypublic NumericValidator()
public NumericValidator(java.lang.String pErrorCode,
                        boolean pRequired)
pRequired - whether the validator is required.pErrorCode - the error code to use.public NumericValidator(java.lang.String pErrorCode)
pErrorCode - the error code to use.public NumericValidator(boolean pRequired)
pRequired - whether the validator is required.public NumericValidator(java.lang.String pErrorCode,
                        boolean pRequired,
                        int pMaxLength)
pErrorCode - the error code to use.pRequired - whether the validator is required.pMaxLength - the maximum length of the string.public java.lang.String validateValue(java.lang.String pPropertyName,
                                      java.lang.Object pPropertyValue,
                                      ValidatorContext<?> pContext)
Checks for the value of is this property is a valid number.
validateValue in interface Validator<java.lang.String>validateValue in class Validators.StringValidatorpPropertyName - the name of the property being validated. This
   is typically used as a key for fetching the value from pProperties.pPropertyValue - the fetched property valuepContext - the current validation context.