PHP Class FOF30\Input\Input

Inheritance: extends JInput
Afficher le fichier Open project: akeeba/fof Class Usage Examples

Méthodes publiques

Méthode Description
__call ( mixed $name, string $arguments ) : boolean Magic method to get filtered input data.
__construct ( array | string | object | null $source = null, array $options = [] ) Public constructor. Overridden to allow specifying the global input array to use as a string and instantiate from an object holding variables.
get ( string $name, mixed $default = null, string $filter = 'cmd', integer $mask ) : mixed Gets a value from the input data. Overridden to allow specifying a filter mask.
getData ( ) : array Returns a copy of the raw data stored in the class

Méthodes protégées

Méthode Description
_cleanVar ( mixed $var, integer $mask, string $type = null ) : mixed Custom filter implementation. Works better with arrays and allows the use of a filter mask.

Method Details

__call() public méthode

Magic method to get filtered input data.
public __call ( mixed $name, string $arguments ) : boolean
$name mixed Name of the value to get.
$arguments string [0] The name of the variable [1] The default value [2] Mask
Résultat boolean The filtered boolean input value.

__construct() public méthode

Public constructor. Overridden to allow specifying the global input array to use as a string and instantiate from an object holding variables.
public __construct ( array | string | object | null $source = null, array $options = [] )
$source array | string | object | null Source data; set null to use $_REQUEST
$options array Filter options

_cleanVar() protected méthode

Custom filter implementation. Works better with arrays and allows the use of a filter mask.
protected _cleanVar ( mixed $var, integer $mask, string $type = null ) : mixed
$var mixed The variable (value) to clean
$mask integer The clean mask
$type string The variable type
Résultat mixed

get() public méthode

Gets a value from the input data. Overridden to allow specifying a filter mask.
public get ( string $name, mixed $default = null, string $filter = 'cmd', integer $mask ) : mixed
$name string Name of the value to get.
$default mixed Default value to return if variable does not exist.
$filter string Filter to apply to the value.
$mask integer The filter mask
Résultat mixed The filtered input value.

getData() public méthode

Returns a copy of the raw data stored in the class
public getData ( ) : array
Résultat array