Method | Description | |
---|---|---|
__construct ( integer $index, |
Construct a new call data instance. | |
addIterableEvent ( Eloquent\Phony\Call\Event\IterableEvent $iterableEvent ) | Add an iterable event. | |
allCalls ( ) : array |
Get all calls as an array. | |
allEvents ( ) : array |
Get all events as an array. | |
argument ( integer $index ) : mixed | Get an argument by index. | |
arguments ( ) : |
Get the received arguments. | |
callAt ( integer $index ) : Eloquent\Phony\Call\Call | Get a call by index. | |
callCount ( ) : integer | Get the number of calls. | |
callback ( ) : callable | Get the callback. | |
calledEvent ( ) : |
Get the 'called' event. | |
compareSequential ( Eloquent\Phony\Call\Call $a, Eloquent\Phony\Call\Call $b ) : integer | A comparator for ordering calls by sequence number. | |
count ( ) : integer | Get the event count. | |
endEvent ( ) : Eloquent\Phony\Call\Event\EndEvent | null | Get the end event. | |
endTime ( ) : float | null | Get the time at which the call completed. | |
eventAt ( integer $index ) : Eloquent\Phony\Event\Event | Get an event by index. | |
eventCount ( ) : integer | Get the number of events. | |
exception ( ) : Exceptio\Exception | Erro\Error | Get the thrown exception. | |
firstCall ( ) : Eloquent\Phony\Call\Call | Get the first call. | |
firstEvent ( ) : Eloquent\Phony\Event\Event | Get the first event. | |
generatorException ( ) : Exceptio\Exception | Erro\Error | Get the exception thrown from the generator. | |
generatorResponse ( ) : tuple |
Get the response from the generator. | |
generatorReturnValue ( ) : mixed | Get the value returned from the generator. | |
getIterator ( ) : Iterator | Get an iterator for this collection. | |
hasCalls ( ) : boolean | Returns true if this collection contains any calls. | |
hasCompleted ( ) : boolean | Returns true if this call has completed. | |
hasEvents ( ) : boolean | Returns true if this collection contains any events. | |
hasResponded ( ) : boolean | Returns true if this call has responded. | |
index ( ) : integer | Get the call index. | |
isGenerator ( ) : boolean | Returns true if this call has responded with a generator. | |
isIterable ( ) : boolean | Returns true if this call has responded with an iterable. | |
iterableEvents ( ) : array |
Get the iterable events. | |
lastCall ( ) : Eloquent\Phony\Call\Call | Get the last call. | |
lastEvent ( ) : Eloquent\Phony\Event\Event | Get the last event. | |
response ( ) : tuple |
Get the response. | |
responseEvent ( ) : Eloquent\Phony\Call\Event\ResponseEvent | null | Get the response event. | |
responseTime ( ) : float | null | Get the time at which the call responded. | |
returnValue ( ) : mixed | Get the returned value. | |
sequenceNumber ( ) : integer | Get the sequence number. | |
setEndEvent ( Eloquent\Phony\Call\Event\EndEvent $endEvent ) | Set the end event. | |
setResponseEvent ( Eloquent\Phony\Call\Event\ResponseEvent $responseEvent ) | Set the response event. | |
time ( ) : float | Get the time at which the event occurred. |
Method | Description | |
---|---|---|
normalizeIndex ( $size, $index, &$normalized = null ) |
public __construct ( integer $index, |
||
$index | integer | The index of this call. |
$calledEvent | The 'called' event. |
public addIterableEvent ( Eloquent\Phony\Call\Event\IterableEvent $iterableEvent ) | ||
$iterableEvent | Eloquent\Phony\Call\Event\IterableEvent | The iterable event. |
public arguments ( ) : |
||
return | The received arguments. |
public calledEvent ( ) : |
||
return | The 'called' event. |
public static compareSequential ( Eloquent\Phony\Call\Call $a, Eloquent\Phony\Call\Call $b ) : integer | ||
$a | Eloquent\Phony\Call\Call | The first call. |
$b | Eloquent\Phony\Call\Call | The second call. |
return | integer | The comparison value. |
public eventCount ( ) : integer | ||
return | integer | The event count. |
public exception ( ) : Exceptio\Exception | Erro\Error | ||
return | Exceptio\Exception | Erro\Error | The thrown exception. |
public firstCall ( ) : Eloquent\Phony\Call\Call | ||
return | Eloquent\Phony\Call\Call | The call. |
public firstEvent ( ) : Eloquent\Phony\Event\Event | ||
return | Eloquent\Phony\Event\Event | The event. |
public generatorException ( ) : Exceptio\Exception | Erro\Error | ||
return | Exceptio\Exception | Erro\Error | The thrown exception. |
public generatorResponse ( ) : tuple |
||
return | tuple |
public generatorReturnValue ( ) : mixed | ||
return | mixed | The returned value. |
public getIterator ( ) : Iterator | ||
return | Iterator | The iterator. |
public hasCompleted ( ) : boolean | ||
return | boolean | True if this call has completed. |
public hasResponded ( ) : boolean | ||
return | boolean | True if this call has responded. |
public isGenerator ( ) : boolean | ||
return | boolean | True if this call has responded with a generator. |
public isIterable ( ) : boolean | ||
return | boolean | True if this call has responded with an iterable. |
public iterableEvents ( ) : array |
||
return | array |
public lastCall ( ) : Eloquent\Phony\Call\Call | ||
return | Eloquent\Phony\Call\Call | The call. |
public lastEvent ( ) : Eloquent\Phony\Event\Event | ||
return | Eloquent\Phony\Event\Event | The event. |
public responseEvent ( ) : Eloquent\Phony\Call\Event\ResponseEvent | null | ||
return | Eloquent\Phony\Call\Event\ResponseEvent | null | The response event, or null if the call has not yet responded. |
public responseTime ( ) : float | null | ||
return | float | null | The time at which the call responded, in seconds since the Unix epoch, or null if the call has not yet responded. |
public returnValue ( ) : mixed | ||
return | mixed | The returned value. |
public sequenceNumber ( ) : integer | ||
return | integer | The sequence number. |
public setEndEvent ( Eloquent\Phony\Call\Event\EndEvent $endEvent ) | ||
$endEvent | Eloquent\Phony\Call\Event\EndEvent | The end event. |
public setResponseEvent ( Eloquent\Phony\Call\Event\ResponseEvent $responseEvent ) | ||
$responseEvent | Eloquent\Phony\Call\Event\ResponseEvent | The response event. |