ResourceArray
class ResourceArray implements Countable, ArrayAccess, IteratorAggregate, JsonSerializable
A ResourceArray holds the response of an API request if more than one resource has been requested.
In addition to the retrieved items themselves it also provides some access to metadata.
Methods
ResourceArray constructor.
Returns the total amount of resources matching the filter.
The limit used when retrieving this ResourceArray.
The number of skipped resources when retrieving this ResourceArray.
Get the returned values as a PHP array.
{@inheritdoc}
Returns the number of resources in this array.
Returns a \Traversable to allow iterating the ResourceArray.
No description
No description
This method is not implemented since a ResourceArray is read-only.
This method is not implemented since a ResourceArray is read-only.
Details
at line 47
__construct(array $items, int $total, int $limit, int $skip)
ResourceArray constructor.
at line 60
int
getTotal()
Returns the total amount of resources matching the filter.
at line 70
int
getLimit()
The limit used when retrieving this ResourceArray.
at line 80
int
getSkip()
The number of skipped resources when retrieving this ResourceArray.
at line 90
array
getItems()
Get the returned values as a PHP array.
at line 98
jsonSerialize()
{@inheritdoc}
at line 118
int
count()
Returns the number of resources in this array.
at line 130
Traversable
getIterator()
Returns a \Traversable to allow iterating the ResourceArray.
at line 142
bool
offsetExists(mixed $offset)
at line 154
mixed
offsetGet(mixed $offset)
at line 169
offsetSet(mixed $offset, mixed $value)
This method is not implemented since a ResourceArray is read-only.
at line 186
offsetUnset(mixed $offset)
This method is not implemented since a ResourceArray is read-only.