Documentation

ClientInterface

Interface defining a client able to execute commands against Redis.

All the commands exposed by the client generally have the same signature as described by the Redis documentation, but some of them offer an additional and more friendly interface to ease programming which is described in the following list of methods:

Tags
author

Daniele Alessandri suppakilla@gmail.com

Table of Contents

__call()  : mixed
Creates a Redis command with the specified arguments and sends a request to the server.
connect()  : mixed
Opens the underlying connection to the server.
createCommand()  : CommandInterface
Creates a new instance of the specified Redis command.
disconnect()  : mixed
Closes the underlying connection from the server.
executeCommand()  : mixed
Executes the specified Redis command.
getConnection()  : ConnectionInterface
Returns the underlying connection instance.
getOptions()  : OptionsInterface
Returns the client options specified upon initialization.
getProfile()  : ProfileInterface
Returns the server profile used by the client.

Methods

__call()

Creates a Redis command with the specified arguments and sends a request to the server.

public __call(string $method, array<string|int, mixed> $arguments) : mixed
Parameters
$method : string

Command ID.

$arguments : array<string|int, mixed>

Arguments for the command.

Return values
mixed

connect()

Opens the underlying connection to the server.

public connect() : mixed
Return values
mixed

createCommand()

Creates a new instance of the specified Redis command.

public createCommand(string $method[, array<string|int, mixed> $arguments = array() ]) : CommandInterface
Parameters
$method : string

Command ID.

$arguments : array<string|int, mixed> = array()

Arguments for the command.

Return values
CommandInterface

disconnect()

Closes the underlying connection from the server.

public disconnect() : mixed
Return values
mixed

Search results