Documentation

MixedStore
in package
implements ArrayAccess

Similar to PHP array, but allows any type of data to act as key (including arrays, objects, scalars)

Note: unfortunately when storing array as key - access and modification is O(N) (yet this should rarely be the case and should be avoided when possible)

Interfaces, Classes, Traits and Enums

ArrayAccess

Table of Contents

$arrayKeys  : array<string|int, callable>
$arrayValues  : array<string|int, EnumValueDefinition>
$falseValue  : mixed
$falseValueIsSet  : bool
$floatStore  : array<string|int, mixed>
$lastArrayKey  : array<string|int, callable>
$lastArrayValue  : mixed
$nullValue  : mixed
$nullValueIsSet  : bool
$objectStore  : SplObjectStorage
$standardStore  : array<string|int, EnumValueDefinition>
$trueValue  : mixed
$trueValueIsSet  : bool
__construct()  : mixed
offsetExists()  : bool
Whether a offset exists
offsetGet()  : mixed
Offset to retrieve
offsetSet()  : void
Offset to set
offsetUnset()  : void
Offset to unset

Properties

$arrayKeys

private array<string|int, callable> $arrayKeys

$floatStore

private array<string|int, mixed> $floatStore

$lastArrayKey

private array<string|int, callable> $lastArrayKey

$objectStore

private SplObjectStorage $objectStore

Methods

__construct()

public __construct() : mixed
Return values
mixed

offsetExists()

Whether a offset exists

public offsetExists(mixed $offset) : bool
Parameters
$offset : mixed

An offset to check for.

Tags
link
http://php.net/manual/en/arrayaccess.offsetexists.php
Return values
bool

true on success or false on failure.

The return value will be casted to boolean if non-boolean was returned.

Search results