PHP 클래스 Predis\Replication\ReplicationStrategy

저자: Daniele Alessandri ([email protected])
파일 보기 프로젝트 열기: tillkruss/redis-object-cache 1 사용 예제들

보호된 프로퍼티들

프로퍼티 타입 설명
$disallowed
$readonly
$readonlySHA1

공개 메소드들

메소드 설명
__construct ( )
isDisallowedOperation ( Predis\Command\CommandInterface $command ) : boolean Returns if the specified command is not allowed for execution in a master slave replication context.
isReadOperation ( Predis\Command\CommandInterface $command ) : boolean Returns if the specified command will perform a read-only operation on Redis or not.
setCommandReadOnly ( string $commandID, mixed $readonly = true ) Marks a command as a read-only operation.
setScriptReadOnly ( string $script, mixed $readonly = true ) Marks a Lua script for EVAL and EVALSHA as a read-only operation. When the behaviour of a script can be decided only at runtime depending on its arguments, a callable object can be provided to dynamically check if the passed instance of EVAL or EVALSHA performs write operations or not.

보호된 메소드들

메소드 설명
getDisallowedOperations ( ) : array Returns the default list of disallowed commands.
getReadOnlyOperations ( ) : array Returns the default list of commands performing read-only operations.
isBitfieldReadOnly ( Predis\Command\CommandInterface $command ) : boolean Checks if BITFIELD performs a read-only operation by looking for certain SET and INCRYBY modifiers in the arguments array of the command.
isGeoradiusReadOnly ( Predis\Command\CommandInterface $command ) : boolean Checks if a GEORADIUS command is a readable operation by parsing the arguments array of the specified commad instance.
isSortReadOnly ( Predis\Command\CommandInterface $command ) : boolean Checks if a SORT command is a readable operation by parsing the arguments array of the specified commad instance.

메소드 상세

__construct() 공개 메소드

public __construct ( )

getDisallowedOperations() 보호된 메소드

Returns the default list of disallowed commands.
protected getDisallowedOperations ( ) : array
리턴 array

getReadOnlyOperations() 보호된 메소드

Returns the default list of commands performing read-only operations.
protected getReadOnlyOperations ( ) : array
리턴 array

isBitfieldReadOnly() 보호된 메소드

Checks if BITFIELD performs a read-only operation by looking for certain SET and INCRYBY modifiers in the arguments array of the command.
protected isBitfieldReadOnly ( Predis\Command\CommandInterface $command ) : boolean
$command Predis\Command\CommandInterface Command instance.
리턴 boolean

isDisallowedOperation() 공개 메소드

Returns if the specified command is not allowed for execution in a master slave replication context.
public isDisallowedOperation ( Predis\Command\CommandInterface $command ) : boolean
$command Predis\Command\CommandInterface Command instance.
리턴 boolean

isGeoradiusReadOnly() 보호된 메소드

Checks if a GEORADIUS command is a readable operation by parsing the arguments array of the specified commad instance.
protected isGeoradiusReadOnly ( Predis\Command\CommandInterface $command ) : boolean
$command Predis\Command\CommandInterface Command instance.
리턴 boolean

isReadOperation() 공개 메소드

Returns if the specified command will perform a read-only operation on Redis or not.
public isReadOperation ( Predis\Command\CommandInterface $command ) : boolean
$command Predis\Command\CommandInterface Command instance.
리턴 boolean

isSortReadOnly() 보호된 메소드

Checks if a SORT command is a readable operation by parsing the arguments array of the specified commad instance.
protected isSortReadOnly ( Predis\Command\CommandInterface $command ) : boolean
$command Predis\Command\CommandInterface Command instance.
리턴 boolean

setCommandReadOnly() 공개 메소드

When the behavior of a command can be decided only at runtime depending on its arguments, a callable object can be provided to dynamically check if the specified command performs a read or a write operation.
public setCommandReadOnly ( string $commandID, mixed $readonly = true )
$commandID string Command ID.
$readonly mixed A boolean value or a callable object.

setScriptReadOnly() 공개 메소드

Marks a Lua script for EVAL and EVALSHA as a read-only operation. When the behaviour of a script can be decided only at runtime depending on its arguments, a callable object can be provided to dynamically check if the passed instance of EVAL or EVALSHA performs write operations or not.
public setScriptReadOnly ( string $script, mixed $readonly = true )
$script string Body of the Lua script.
$readonly mixed A boolean value or a callable object.

프로퍼티 상세

$disallowed 보호되어 있는 프로퍼티

protected $disallowed

$readonly 보호되어 있는 프로퍼티

protected $readonly

$readonlySHA1 보호되어 있는 프로퍼티

protected $readonlySHA1