size<T> static method
when valid
- value is null
- min == null && max == null
- value's length is > min and < max
Implementation
static FormeValidator<T> size<T>(
{String errorText = '', int? min, int? max}) {
return (f, T v) {
if (v == null) {
return null;
}
if (min == null && max == null) {
return null;
}
return _validateSize(_getLength(v), min, max, errorText: errorText);
};
}