toArray()
toArray() : array
Get the array representation of an object
Iterates over a paginated resource using subsequent requests in order to retrieve the entire matching result set
setEventDispatcher(\Symfony\Component\EventDispatcher\EventDispatcherInterface $eventDispatcher) : self
Set the EventDispatcher of the request
\Symfony\Component\EventDispatcher\EventDispatcherInterface | $eventDispatcher |
getEventDispatcher() : \Symfony\Component\EventDispatcher\EventDispatcherInterface
Get the EventDispatcher of the request
dispatch(string $eventName, array $context = array()) : \Guzzle\Common\Event
Helper to dispatch Guzzle events and set the event name on the event
string | $eventName | Name of the event to dispatch |
array | $context | Context of the event |
Returns the created event object
addSubscriber(\Symfony\Component\EventDispatcher\EventSubscriberInterface $subscriber) : self
Add an event subscriber to the dispatcher
\Symfony\Component\EventDispatcher\EventSubscriberInterface | $subscriber | Event subscriber |
setLimit(integer $limit) : \Guzzle\Service\Resource\ResourceIteratorInterface
Attempt to limit the total number of resources returned by the iterator.
You may still receive more items than you specify. Set to 0 to specify no limit.
integer | $limit | Limit amount |
setPageSize(integer $pageSize) : \Guzzle\Service\Resource\ResourceIteratorInterface
Attempt to limit the total number of resources retrieved per request by the iterator.
The iterator may return more than you specify in the page size argument depending on the service and underlying command implementation. Set to 0 to specify no page size limitation.
integer | $pageSize | Limit amount |
set(string $key, mixed $value) : \Guzzle\Service\Resource\ResourceIteratorInterface
Set a data option on the iterator
string | $key | Key of the option to set |
mixed | $value | Value to set for the option |
<?php
namespace Guzzle\Service\Resource;
use Guzzle\Common\HasDispatcherInterface;
use Guzzle\Common\ToArrayInterface;
/**
* Iterates over a paginated resource using subsequent requests in order to retrieve the entire matching result set
*/
interface ResourceIteratorInterface extends ToArrayInterface, HasDispatcherInterface, \Iterator, \Countable
{
/**
* Retrieve the NextToken that can be used in other iterators.
*
* @return string Returns a NextToken
*/
public function getNextToken();
/**
* Attempt to limit the total number of resources returned by the iterator.
*
* You may still receive more items than you specify. Set to 0 to specify no limit.
*
* @param int $limit Limit amount
*
* @return ResourceIteratorInterface
*/
public function setLimit($limit);
/**
* Attempt to limit the total number of resources retrieved per request by the iterator.
*
* The iterator may return more than you specify in the page size argument depending on the service and underlying
* command implementation. Set to 0 to specify no page size limitation.
*
* @param int $pageSize Limit amount
*
* @return ResourceIteratorInterface
*/
public function setPageSize($pageSize);
/**
* Get a data option from the iterator
*
* @param string $key Key of the option to retrieve
*
* @return mixed|null Returns NULL if not set or the value if set
*/
public function get($key);
/**
* Set a data option on the iterator
*
* @param string $key Key of the option to set
* @param mixed $value Value to set for the option
*
* @return ResourceIteratorInterface
*/
public function set($key, $value);
}