Predis\Cluster\ClusterStrategy::getSlot PHP Méthode

getSlot() public méthode

public getSlot ( Predis\Command\CommandInterface $command )
$command Predis\Command\CommandInterface
    public function getSlot(CommandInterface $command)
    {
        $slot = $command->getSlot();
        if (!isset($slot) && isset($this->commands[$cmdID = $command->getId()])) {
            $key = call_user_func($this->commands[$cmdID], $command);
            if (isset($key)) {
                $slot = $this->getSlotByKey($key);
                $command->setSlot($slot);
            }
        }
        return $slot;
    }