class deactivated_super_global implements ArrayAccess, Countable, IteratorAggregate

Replacement for a superglobal (like $_GET or $_POST) which calls trigger_error on all operations but isset, overloads the [] operator with SPL.

Methods

__construct(request_interface $request, string $name, string $super_global)

Constructor generates an error message fitting the super global to be used within the other functions.

bool
offsetExists(string $offset)

Redirects isset to the correct request class call.

offsetGet($offset)

No description

offsetSet($offset, $value)

No description

offsetUnset($offset)

No description

count()

Part of the \Countable implementation, will always result in a FATAL error

getIterator()

Part of the Traversable/IteratorAggregate implementation, will always result in a FATAL error

Details

at line 44
__construct(request_interface $request, string $name, string $super_global)

Constructor generates an error message fitting the super global to be used within the other functions.

Parameters

request_interface $request

A request class instance holding the real super global data.

string $name

Name of the super global this is a replacement for - e.g. '_GET'.

string $super_global

The variable's super global constant (\phpbb\request\request_interface::POST|GET|REQUEST|COOKIE).

at line 77
bool offsetExists(string $offset)

Redirects isset to the correct request class call.

Parameters

string $offset

The key of the super global being accessed.

Return Value

bool

Whether the key on the super global exists.

at line 85
offsetGet($offset)

No description

Parameters

$offset

at line 90
offsetSet($offset, $value)

No description

Parameters

$offset
$value

at line 95
offsetUnset($offset)

No description

Parameters

$offset

at line 104
count()

Part of the \Countable implementation, will always result in a FATAL error

at line 112
getIterator()

Part of the Traversable/IteratorAggregate implementation, will always result in a FATAL error