ConnectionException
extends CommunicationException
in package
Exception class that identifies connection-related errors.
Tags
Table of Contents
- $connection : mixed
- __construct() : mixed
- getConnection() : NodeConnectionInterface
- Gets the connection that generated the exception.
- handle() : mixed
- Helper method to handle exceptions generated by a connection object.
- shouldResetConnection() : bool
- Indicates if the receiver should reset the underlying connection.
Properties
$connection
private
mixed
$connection
Methods
__construct()
public
__construct(NodeConnectionInterface $connection[, string $message = null ][, int $code = null ][, Exception $innerException = null ]) : mixed
Parameters
- $connection : NodeConnectionInterface
-
Connection that generated the exception.
- $message : string = null
-
Error message.
- $code : int = null
-
Error code.
- $innerException : Exception = null
-
Inner exception for wrapping the original error.
Return values
mixed —getConnection()
Gets the connection that generated the exception.
public
getConnection() : NodeConnectionInterface
Return values
NodeConnectionInterface —handle()
Helper method to handle exceptions generated by a connection object.
public
static handle(CommunicationException $exception) : mixed
Parameters
- $exception : CommunicationException
-
Exception.
Tags
Return values
mixed —shouldResetConnection()
Indicates if the receiver should reset the underlying connection.
public
shouldResetConnection() : bool