Class MaxLength
Check if the length (or size) of input is lower than specified length
-
Wei\Base
-
Wei\Validator\BaseValidator
-
Wei\Validator\Length
-
Wei\Validator\MaxLength
Methods summary
public
boolean
|
#
__invoke( mixed $input, $max = null, $__ = null )
Validate the input value
Parameters
Returns
boolean
Overrides
|
protected
boolean
|
#
doValidate( mixed $input )
Validate the input value (ignore the $negative property)
Validate the input value (ignore the $negative property)
Parameters
- $input
- The input to be validated
Returns
boolean
Overrides
|
Methods inherited from Wei\Validator\BaseValidator
addError(),
getErrors(),
getFirstMessage(),
getJoinedMessage(),
getMessages(),
getName(),
hasError(),
isString(),
isValid(),
loadTranslationMessages(),
setMessages(),
setName(),
storeOption()
|
Properties summary
protected
string
|
$tooLongMessage
|
#
'%name% must have a length lower than %max%'
|
protected
string
|
$tooManyMessage
|
#
'%name% must contain no more than %max% items'
|
protected
|
$max
|
|