public final class ParameterValidator
extends java.lang.Object
Modifier and Type | Method and Description |
---|---|
void |
assertNone(java.lang.String paramName,
ParameterList parameters)
Ensure a parameter doesn't occur in the specified list.
|
void |
assertNullOrEqual(Parameter param,
ParameterList parameters) |
void |
assertOne(java.lang.String paramName,
ParameterList parameters)
Ensure a parameter occurs once.
|
void |
assertOneOrLess(java.lang.String paramName,
ParameterList parameters)
Ensure a parameter occurs no more than once.
|
static ParameterValidator |
getInstance() |
public void assertOneOrLess(java.lang.String paramName, ParameterList parameters) throws ValidationException
paramName
- the parameter nameparameters
- a list of parameters to queryValidationException
- when the specified parameter occurs more than oncepublic void assertOne(java.lang.String paramName, ParameterList parameters) throws ValidationException
paramName
- the parameter nameparameters
- a list of parameters to queryValidationException
- when the specified parameter does not occur oncepublic void assertNone(java.lang.String paramName, ParameterList parameters) throws ValidationException
paramName
- the name of a parameterparameters
- a list of parametersValidationException
- thrown when the specified property
is found in the list of propertiespublic void assertNullOrEqual(Parameter param, ParameterList parameters) throws ValidationException
param
- a parameter instanceparameters
- a list of parametersValidationException
- where the assertion failspublic static ParameterValidator getInstance()
Copyright © 2004-2015 Micronode. All Rights Reserved.