Module rxmicro.validation
Package io.rxmicro.validation.validator
Class MinLengthConstraintValidator
- java.lang.Object
-
- io.rxmicro.validation.base.AbstractMinConstraintValidator<Integer>
-
- io.rxmicro.validation.validator.MinLengthConstraintValidator
-
- All Implemented Interfaces:
ConstraintValidator<String>
public class MinLengthConstraintValidator extends AbstractMinConstraintValidator<Integer> implements ConstraintValidator<String>
Validator for theMinLengthconstraint.- Since:
- 0.1
- Author:
- nedis
- See Also:
MinLength
-
-
Field Summary
-
Fields inherited from class io.rxmicro.validation.base.AbstractMinConstraintValidator
inclusive, minValue
-
-
Constructor Summary
Constructors Constructor Description MinLengthConstraintValidator(int minValue, boolean inclusive)Creates the default instance ofMinLengthConstraintValidatorwith the specified parameters.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidvalidate(String value, HttpModelType httpModelType, String modelName)Validates the single actual.-
Methods inherited from class io.rxmicro.validation.base.AbstractMinConstraintValidator
validate
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface io.rxmicro.validation.ConstraintValidator
validate, validateIterable, validateIterable, validateMapValues, validateMapValues
-
-
-
-
Constructor Detail
-
MinLengthConstraintValidator
public MinLengthConstraintValidator(int minValue, boolean inclusive)Creates the default instance ofMinLengthConstraintValidatorwith the specified parameters.- Parameters:
minValue- the supported min value.inclusive- whether the specified minimum is inclusive or exclusive.
-
-
Method Detail
-
validate
public void validate(String value, HttpModelType httpModelType, String modelName)
Description copied from interface:ConstraintValidatorValidates the single actual.The state of the
actualmust not be altered.- Specified by:
validatein interfaceConstraintValidator<String>- Parameters:
value- the actual value to validatehttpModelType- the http model typemodelName- the parameter or header name
-
-