Method |
Description |
|
__construct ( ) |
Constructor. |
|
__get ( string $offset ) : mixed |
Magic getter for easier retrieving of values. |
|
all ( ) : self |
Validates all variables. |
|
check ( mixed $var, string $name ) : self |
Starts a new value checking. |
|
close ( ) : self |
Closes a chain. |
|
condition ( string $name, mixed $param = null ) : self |
Adds a conditional chain. |
|
defaultValue ( mixed $value ) : self |
Sets a default value in case the validation fails. |
|
file ( string $index ) : self |
Checks file upload. |
|
filter ( string $name, mixed $param = null ) : self |
Adds a filter to the chain.s |
|
getErrors ( ) : array |
Returns errors. |
|
getValue ( string $name ) : mixed |
Returns a value by name. |
|
getValues ( ) : array |
Returns all values. |
|
isValid ( boolean $assocErrors = false ) : boolean |
Performs validation and filtering of all variables. |
|
post ( string $name, mixed $default = null ) : self |
Checks a POST variable. |
|
query ( string $name, mixed $default = null ) : self |
Checks a GET variable. |
|
request ( string $name, mixed $default = null ) : self |
Checks a POST/GET variable |
|
validate ( string $name, string $errorMessage = null, mixed $param = null ) : self |
Adds a validator to the chain. |
|
validateAll ( ) |
Calls isValid(), but throws an exception on error. |
|
walk ( boolean $addFilter = true ) : self |
Adds a subchain to the current chain that treats the value a an array. |
|