trait PacksPhpRedisValues (View source)

Properties

protected bool|null $supportsPacking

Indicates if Redis supports packing.

protected bool|null $supportsLzf

Indicates if Redis supports LZF compression.

protected bool|null $supportsZstd

Indicates if Redis supports Zstd compression.

Methods

array
pack(array $values)

Prepares the given values to be used with the eval command, including serialization and compression.

bool
compressed()

Determine if compression is enabled.

bool
lzfCompressed()

Determine if LZF compression is enabled.

bool
zstdCompressed()

Determine if ZSTD compression is enabled.

bool
lz4Compressed()

Determine if LZ4 compression is enabled.

bool
supportsPacking()

Determine if the current PhpRedis extension version supports packing.

bool
supportsLzf()

Determine if the current PhpRedis extension version supports LZF compression.

bool
supportsZstd()

Determine if the current PhpRedis extension version supports Zstd compression.

bool
phpRedisVersionAtLeast(string $version)

Determine if the PhpRedis extension version is at least the given version.

Details

array pack(array $values)

Prepares the given values to be used with the eval command, including serialization and compression.

Parameters

array $values

Return Value

array

bool compressed()

Determine if compression is enabled.

Return Value

bool

bool lzfCompressed()

Determine if LZF compression is enabled.

Return Value

bool

bool zstdCompressed()

Determine if ZSTD compression is enabled.

Return Value

bool

bool lz4Compressed()

Determine if LZ4 compression is enabled.

Return Value

bool

protected bool supportsPacking()

Determine if the current PhpRedis extension version supports packing.

Return Value

bool

protected bool supportsLzf()

Determine if the current PhpRedis extension version supports LZF compression.

Return Value

bool

protected bool supportsZstd()

Determine if the current PhpRedis extension version supports Zstd compression.

Return Value

bool

protected bool phpRedisVersionAtLeast(string $version)

Determine if the PhpRedis extension version is at least the given version.

Parameters

string $version

Return Value

bool