Class

Imagine\Image\Metadata\MetadataBag

class MetadataBag implements ArrayAccess, IteratorAggregate, Countable

An interface for Image Metadata

Methods

__construct(array $data = array())

mixed get(string $key, mixed|null $default = null)

Returns the metadata key, default value if it does not exist

count()

{@inheritdoc}

getIterator()

{@inheritdoc}

offsetExists($offset)

{@inheritdoc}

offsetSet($offset, $value)

{@inheritdoc}

offsetUnset($offset)

{@inheritdoc}

offsetGet($offset)

{@inheritdoc}

array toArray()

Returns metadata as an array

Details

at line 22
public __construct(array $data = array())

Parameters

array $data

at line 35
public mixed get(string $key, mixed|null $default = null)

Returns the metadata key, default value if it does not exist

Parameters

string $key
mixed|null $default

Return Value

mixed

at line 43
public count()

{@inheritdoc}

at line 51
public getIterator()

{@inheritdoc}

at line 59
public offsetExists($offset)

{@inheritdoc}

Parameters

$offset

at line 67
public offsetSet($offset, $value)

{@inheritdoc}

Parameters

$offset
$value

at line 75
public offsetUnset($offset)

{@inheritdoc}

Parameters

$offset

at line 83
public offsetGet($offset)

{@inheritdoc}

Parameters

$offset

at line 93
public array toArray()

Returns metadata as an array

Return Value

array An associative array