PHP Class Jyxo\Input\Validator\LessThan

..
Author: Jan Pěček
Inheritance: extends AbstractValidator
ファイルを表示 Open project: jyxo/php

Protected Properties

Property Type Description
$max integer Desired maximum value

Public Methods

Method Description
__construct ( integer $max ) Constructor.
getMax ( ) : integer Returns the maximum value.
isValid ( mixed $value ) : boolean Validates a value.
setMax ( integer $max ) : self Sets the maximum value.

Method Details

__construct() public method

Sets maximum value.
public __construct ( integer $max )
$max integer Maximum value (value must be less)

getMax() public method

Returns the maximum value.
public getMax ( ) : integer
return integer

isValid() public method

Validates a value.
public isValid ( mixed $value ) : boolean
$value mixed Input value
return boolean

setMax() public method

Sets the maximum value.
public setMax ( integer $max ) : self
$max integer New maximum value
return self

Property Details

$max protected_oe property

Desired maximum value
protected int $max
return integer