PHP Class Bluz\Validator\Rule\Max

Inheritance: extends AbstractCompareRule
Show file Open project: bluzphp/framework Class Usage Examples

Protected Properties

Property Type Description
$maxValue maximum value

Public Methods

Method Description
__construct ( numeric $maxValue, boolean $inclusive = false ) Setup validation rule
getTemplate ( ) : string Get error template
validate ( numeric $input ) : boolean Check input data

Method Details

__construct() public method

Setup validation rule
public __construct ( numeric $maxValue, boolean $inclusive = false )
$maxValue numeric
$inclusive boolean

getTemplate() public method

Get error template
public getTemplate ( ) : string
return string

validate() public method

Check input data
public validate ( numeric $input ) : boolean
$input numeric
return boolean

Property Details

$maxValue protected property

maximum value
protected $maxValue