This interface describes an input provider.

An input provider provides access to parameters, values and persistent values.

 Methods

Retrieve a request parameter.

getParameter(string $strKey, bool $blnRaw) : mixed
In plain HTTP, this will be a $_GET parameter, for other implementations consult the API.

Parameters

$strKey

string

The name of the parameter to be retrieved.

$blnRaw

bool

Boolean flag to determine if the content shall be returned RAW or rather be stripped of potential malicious content.

Returns

mixed

Retrieve a persistent value.

getPersistentValue(string $strKey) : mixed
Usually this value is being kept in the user session.
deprecated Use Environment::getSessionStorage()->get() instead.

Parameters

$strKey

string

The name of the value to be retrieved.

Returns

mixed

Retrieve the current request url.

getRequestUrl() : string

Returns

string

Retrieve a request value.

getValue(string $strKey, bool $blnRaw) : mixed
In plain HTTP, this will be a $_POST value, for other implementations consult the API.

Parameters

$strKey

string

The name of the value to be retrieved.

$blnRaw

bool

Boolean flag to determine if the content shall be returned RAW or rather be stripped of potential malicious content.

Returns

mixed

Determines if a request parameter is defined.

hasParameter(string $strKey) : bool
In plain HTTP, this will be a $_GET parameter, for other implementations consult the API.

Parameters

$strKey

string

The name of the parameter to be checked.

Returns

bool

Determines if a persistent value is defined.

hasPersistentValue(string $strKey) : bool
Usually this value is being kept in the user session.
deprecated Use Environment::getSessionStorage()->has() instead.

Parameters

$strKey

string

The name of the value to be checked.

Returns

bool

Determines if a request value is defined.

hasValue(string $strKey) : bool
In plain HTTP, this will be a $_POST value, for other implementations consult the API.

Parameters

$strKey

string

The name of the value to be checked.

Returns

bool

Save/change a request parameter.

setParameter(string $strKey, mixed $varValue) : \ContaoCommunityAlliance\DcGeneral\InputProviderInterface
In plain HTTP, this will be a $_GET parameter, for other implementations consult the API.

Parameters

$strKey

string

The name of the parameter to be stored.

$varValue

mixed

The value to be stored.

Returns

Save/change a persistent value.

setPersistentValue(string $strKey, mixed $varValue) : \ContaoCommunityAlliance\DcGeneral\InputProviderInterface
Usually this value is being kept in the user session.
deprecated Use Environment::getSessionStorage()->set() instead.

Parameters

$strKey

string

The name of the value to be stored.

$varValue

mixed

The value to be stored.

Returns

Save/change a request value.

setValue(string $strKey, mixed $varValue) : \ContaoCommunityAlliance\DcGeneral\InputProviderInterface
In plain HTTP, this will be a $_POST value, for other implementations consult the API.

Parameters

$strKey

string

The name of the value to be stored.

$varValue

mixed

The value to be stored.

Returns

Unset a request parameter.

unsetParameter(string $strKey) : \ContaoCommunityAlliance\DcGeneral\InputProviderInterface
In plain HTTP, this will be a $_GET parameter, for other implementations consult the API.

Parameters

$strKey

string

The name of the parameter to be removed.

Returns

Unset a request value.

unsetValue(string $strKey) : \ContaoCommunityAlliance\DcGeneral\InputProviderInterface
In plain HTTP, this will be a $_POST value, for other implementations consult the API.

Parameters

$strKey

string

The name of the value to be removed.

Returns