- BadTargetClassException
- BadTargetInterfaceException
- BadTargetTypeException
- DeferredCallChain
- TargetAlreadyDefinedException
- UndefinedTargetClassException
Thrown when applying a deferred call chain on a target which is not an instance of the expected class.
- Full name: \JClaveau\Async\Exceptions\BadTargetClassException
- Parent class:
Constructor.
BadTargetClassException::__construct( \JClaveau\Async\DeferredCallChain $callchain, mixed $expected_target, mixed $target )
Parameters:
Parameter | Type | Description |
---|---|---|
$callchain |
\JClaveau\Async\DeferredCallChain | |
$expected_target |
mixed | The expected class |
$target |
mixed |
Thrown when applying a deferred call chain on a target which doesn't implement the expected interface.
- Full name: \JClaveau\Async\Exceptions\BadTargetInterfaceException
- Parent class:
Constructor.
BadTargetInterfaceException::__construct( \JClaveau\Async\DeferredCallChain $callchain, mixed $expected_target, mixed $target )
Parameters:
Parameter | Type | Description |
---|---|---|
$callchain |
\JClaveau\Async\DeferredCallChain | |
$expected_target |
mixed | The expected interface |
$target |
mixed |
Thrown when applying a deferred call chain on a target which is not of the expected type.
- Full name: \JClaveau\Async\Exceptions\BadTargetTypeException
- Parent class:
Constructor.
BadTargetTypeException::__construct( \JClaveau\Async\DeferredCallChain $callchain, mixed $expected_target, mixed $target )
Parameters:
Parameter | Type | Description |
---|---|---|
$callchain |
\JClaveau\Async\DeferredCallChain | |
$expected_target |
mixed | The expected type |
$target |
mixed |
This class stores an arbitrary stack of calls (methods or array entries access) that will be callable on any future variable.
- Full name: \JClaveau\Async\DeferredCallChain
- This class implements: \JsonSerializable, \ArrayAccess
Unused part of the ArrayAccess interface
DeferredCallChain::offsetSet( $offset, $value )
Parameters:
Parameter | Type | Description |
---|---|---|
$offset |
**** | |
$value |
**** |
Unused part of the ArrayAccess interface
DeferredCallChain::offsetExists( $offset )
Parameters:
Parameter | Type | Description |
---|---|---|
$offset |
**** |
Unused part of the ArrayAccess interface
DeferredCallChain::offsetUnset( $offset )
Parameters:
Parameter | Type | Description |
---|---|---|
$offset |
**** |
For implementing JsonSerializable interface.
DeferredCallChain::jsonSerialize( )
See Also:
Outputs the PHP code producing the current call chain while it's casted as a string.
DeferredCallChain::__toString( ): string
Return Value:
The PHP code corresponding to this call chain
Outputs the PHP code producing the current call chain while it's casted as a string.
DeferredCallChain::toString( array $options = array() ): string
Parameters:
Parameter | Type | Description |
---|---|---|
$options |
array | target: mixed | max_parameter_length: int | short_objects: bool |
Return Value:
The PHP code corresponding to this call chain
Constructor
DeferredCallChain::__construct( string $class_type_interface_or_instance = null )
Parameters:
Parameter | Type | Description |
---|---|---|
$class_type_interface_or_instance |
string | The expected target class/type/interface/instance |
Stores any call in the the stack.
DeferredCallChain::__call( string $method, array $arguments ): $this
Parameters:
Parameter | Type | Description |
---|---|---|
$method |
string | |
$arguments |
array |
ArrayAccess interface
DeferredCallChain::offsetGet( string $key )
Parameters:
Parameter | Type | Description |
---|---|---|
$key |
string | The entry to acces |
Invoking the instance produces the call of the stack
DeferredCallChain::__invoke( mixed $target = null ): mixed
Parameters:
Parameter | Type | Description |
---|---|---|
$target |
mixed | The target to apply the callchain on |
Return Value:
The value returned once the call chain is called uppon $target
Thrown when applying a deferred call chain on a target which is already defined.
- Full name: \JClaveau\Async\Exceptions\TargetAlreadyDefinedException
- Parent class:
Constructor.
TargetAlreadyDefinedException::__construct( \JClaveau\Async\DeferredCallChain $callchain, mixed $expected_target, mixed $target )
Parameters:
Parameter | Type | Description |
---|---|---|
$callchain |
\JClaveau\Async\DeferredCallChain | |
$expected_target |
mixed | The target instance |
$target |
mixed |
Thrown when defining an expected target which is not an existing class, an existing interface or native type.
- Full name: \JClaveau\Async\Exceptions\UndefinedTargetClassException
- Parent class:
Constructor.
UndefinedTargetClassException::__construct( \JClaveau\Async\DeferredCallChain $callchain, mixed $expected_target )
Parameters:
Parameter | Type | Description |
---|---|---|
$callchain |
\JClaveau\Async\DeferredCallChain | |
$expected_target |
mixed | The wrong expected target |
This document was automatically generated from source code comments on 2019-11-12 using phpDocumentor and cvuorinen/phpdoc-markdown-public