public class ParameterValidator extends Object
Constructor and Description |
---|
ParameterValidator() |
Modifier and Type | Method and Description |
---|---|
static <T> void |
arrayLessThanOrEqualTo(String parameterName,
T[] value,
int length) |
static <T> void |
arrayNotEmpty(String parameterName,
T[] value) |
static URI |
getValidURI(String aParamName,
String aValue) |
static void |
numberGreaterThan(String parameterName,
Number value,
double threshold) |
static void |
numberGreaterThanOrEqualsTo(String parameterName,
Number value,
double threshold) |
static void |
numberLessThan(String parameterName,
Number value,
double threshold) |
static void |
numberLessThanOrEqualsTo(String parameterName,
Number value,
double threshold) |
static void |
numberNotNegative(String parameterName,
Number value) |
static void |
numberNotZero(String parameterName,
Number value) |
static void |
objectNotNull(String parameterName,
Object value) |
static void |
stringLengthShorterThanOrEqualTo(String parameterName,
String value,
int length) |
static void |
stringNotEmpty(String parameterName,
String value) |
static void |
trimmedStringNotEmpty(String parameterName,
String value) |
public static void objectNotNull(String parameterName, Object value) throws InvalidParameterException
InvalidParameterException
public static void stringNotEmpty(String parameterName, String value) throws InvalidParameterException
InvalidParameterException
public static void trimmedStringNotEmpty(String parameterName, String value) throws InvalidParameterException
InvalidParameterException
public static void numberNotNegative(String parameterName, Number value) throws InvalidParameterException
InvalidParameterException
public static void numberNotZero(String parameterName, Number value) throws InvalidParameterException
InvalidParameterException
public static void numberLessThan(String parameterName, Number value, double threshold) throws InvalidParameterException
InvalidParameterException
public static void numberLessThanOrEqualsTo(String parameterName, Number value, double threshold) throws InvalidParameterException
InvalidParameterException
public static void numberGreaterThan(String parameterName, Number value, double threshold) throws InvalidParameterException
InvalidParameterException
public static void numberGreaterThanOrEqualsTo(String parameterName, Number value, double threshold) throws InvalidParameterException
InvalidParameterException
public static <T> void arrayNotEmpty(String parameterName, T[] value) throws InvalidParameterException
InvalidParameterException
public static <T> void arrayLessThanOrEqualTo(String parameterName, T[] value, int length) throws InvalidParameterException
InvalidParameterException
public static URI getValidURI(String aParamName, String aValue) throws InvalidParameterException
InvalidParameterException
public static void stringLengthShorterThanOrEqualTo(String parameterName, String value, int length) throws InvalidParameterException
InvalidParameterException