Phalcon\Queue\Beanstalk\Extended::getTubeStats PHP Method

getTubeStats() public method

Returns information about the specified tube if it exists.
public getTubeStats ( string $tube ) : null | array
$tube string
return null | array
    public function getTubeStats($tube)
    {
        $result = null;
        $lines = $this->getResponseLines('stats-tube ' . $this->getTubeName($tube));
        if (!empty($lines)) {
            foreach ($lines as $line) {
                if (false !== strpos($line, ':')) {
                    list($name, $value) = explode(':', $line);
                    if (null !== $value) {
                        $result[$name] = intval($value);
                    }
                }
            }
        }
        return $result;
    }