PredisConnection
extends Connection
in package
Tags
Table of Contents
- $client : Client
- The Predis client.
- __call() : mixed
- Pass other method calls down to the underlying client.
- __construct() : void
- Create a new Predis connection.
- client() : mixed
- Get the underlying Redis client.
- command() : mixed
- Run a command against the Redis database.
- createSubscription() : void
- Subscribe to a set of given channels for messages.
- funnel() : ConcurrencyLimiterBuilder
- Funnel a callback for a maximum number of simultaneous executions.
- psubscribe() : void
- Subscribe to a set of given channels with wildcards.
- subscribe() : void
- Subscribe to a set of given channels for messages.
- throttle() : DurationLimiterBuilder
- Throttle a callback for a maximum number of executions over a given duration.
Properties
$client
The Predis client.
protected
Client
$client
Methods
__call()
Pass other method calls down to the underlying client.
public
__call(string $method, array<string|int, mixed> $parameters) : mixed
Parameters
- $method : string
- $parameters : array<string|int, mixed>
Return values
mixed —__construct()
Create a new Predis connection.
public
__construct(Client $client) : void
Parameters
- $client : Client
Return values
void —client()
Get the underlying Redis client.
public
client() : mixed
Return values
mixed —command()
Run a command against the Redis database.
public
command(string $method[, array<string|int, mixed> $parameters = [] ]) : mixed
Parameters
- $method : string
- $parameters : array<string|int, mixed> = []
Return values
mixed —createSubscription()
Subscribe to a set of given channels for messages.
public
createSubscription(array<string|int, mixed>|string $channels, Closure $callback[, string $method = 'subscribe' ]) : void
Parameters
- $channels : array<string|int, mixed>|string
- $callback : Closure
- $method : string = 'subscribe'
Return values
void —funnel()
Funnel a callback for a maximum number of simultaneous executions.
public
funnel(string $name) : ConcurrencyLimiterBuilder
Parameters
- $name : string
Return values
ConcurrencyLimiterBuilder —psubscribe()
Subscribe to a set of given channels with wildcards.
public
psubscribe(array<string|int, mixed>|string $channels, Closure $callback) : void
Parameters
- $channels : array<string|int, mixed>|string
- $callback : Closure
Return values
void —subscribe()
Subscribe to a set of given channels for messages.
public
subscribe(array<string|int, mixed>|string $channels, Closure $callback) : void
Parameters
- $channels : array<string|int, mixed>|string
- $callback : Closure
Return values
void —throttle()
Throttle a callback for a maximum number of executions over a given duration.
public
throttle(string $name) : DurationLimiterBuilder
Parameters
- $name : string