PsrHeaderInput
class PsrHeaderInput extends Input (View source)
The HeaderInput class.
Properties
Input | $get | from Input | |
Input | $post | from Input | |
FormDataInput | $put | from Input | |
FormDataInput | $patch | from Input | |
FormDataInput | $delete | from Input | |
FormDataInput | $link | from Input | |
FormDataInput | $unlink | from Input | |
Input | $request | from Input | |
Input | $server | from Input | |
Input | $env | from Input | |
Input | $header | from Input | |
PsrFilesInput | $files | from Input | |
CookieInput | $cookie | from Input |
Methods
prepareSource
Gets a value from the input data.
Sets a value
Define a value. The value will only be set if there's no value for the name or if it is null.
Gets an array of values from the request.
Get data from array or object by path.
Details
__construct(array $source = null, InputFilter $filter = null)
Constructor.
at line line 28
void
prepareSource(array $source = null, boolean $reference = false)
prepareSource
at line line 52
mixed
get(string $name, mixed $default = null, string $filter = 'cmd', string $separator = '.')
Gets a value from the input data.
at line line 68
set(string $name, mixed $value, string $separator = '.')
Sets a value
def(string $name, mixed $value, string $separator = '.')
Define a value. The value will only be set if there's no value for the name or if it is null.
bool
exists(string $name, string $separator = '.')
Check if a value name exists.
mixed
compact(array $vars = array(), mixed $datasource = null)
Gets an array of values from the request.
mixed
__call(string $name, array $arguments)
Magic method to get filtered input data.
InputFilter
getFilter()
Method to get property Filter
Input
setFilter(InputFilter $filter)
Method to set property filter
static mixed
getByPath(mixed $data, mixed $path, string $separator = '.')
Get data from array or object by path.
Example: ArrayHelper::getByPath($array, 'foo.bar.yoo')
equals to $array['foo']['bar']['yoo'].
static boolean
setByPath(mixed $data, string $path, mixed $value, string $separator = '.', string $storeType = 'array')
setByPath