class ArrayHash extends stdClass implements ArrayAccess, Countable, IteratorAggregate

Provides objects to work as array.

Methods

static ArrayHash
from(array $array, bool $recursive = true)

Transforms array to ArrayHash.

getIterator()

Returns an iterator over all items.

int
count()

Returns items count.

void
offsetSet(string|int $key, mixed $value)

Replaces or appends a item.

mixed
offsetGet(string|int $key)

Returns a item.

bool
offsetExists(string|int $key)

Determines whether a item exists.

void
offsetUnset(string|int $key)

Removes the element from this list.

Details

at line 24
static ArrayHash from(array $array, bool $recursive = true)

Transforms array to ArrayHash.

Parameters

array $array
bool $recursive

Return Value

ArrayHash

at line 41
RecursiveArrayIterator getIterator()

Returns an iterator over all items.

Return Value

RecursiveArrayIterator

at line 50
int count()

Returns items count.

Return Value

int

at line 61
void offsetSet(string|int $key, mixed $value)

Replaces or appends a item.

Parameters

string|int $key
mixed $value

Return Value

void

at line 75
mixed offsetGet(string|int $key)

Returns a item.

Parameters

string|int $key

Return Value

mixed

at line 85
bool offsetExists(string|int $key)

Determines whether a item exists.

Parameters

string|int $key

Return Value

bool

at line 95
void offsetUnset(string|int $key)

Removes the element from this list.

Parameters

string|int $key

Return Value

void