Class Required
Check if the input is provided
-
Wei\Base
-
Wei\Validator\BaseValidator
-
Wei\Validator\Required
Methods summary
public
boolean
|
#
__invoke( mixed $input, $required = 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
|
public
boolean
|
#
isInvalid( mixed $input )
Check if the input is in invalid variables
Check if the input is in invalid variables
Parameters
Returns
boolean
|
Methods inherited from Wei\Validator\BaseValidator
addError(),
getErrors(),
getFirstMessage(),
getJoinedMessage(),
getMessages(),
getName(),
hasError(),
isString(),
isValid(),
loadTranslationMessages(),
setMessages(),
setName(),
storeOption()
|
Properties summary
protected
string
|
$requiredMessage
|
|
protected
boolean
|
$required
Whether the input is required or not
Whether the input is required or not
|
|
protected
array
|
$invalid
The invalid variable values
The invalid variable values
|
#
array(null, '', false, array())
|