public function gets(array $keys, $metadata = false)
    {
        /**
         * gets <key>*\r\n
         */

        // Build key request string
        $keys = implode(self::COMMAND_SEPARATOR, $keys);

        // Build packet to send ...
        $data = self::COMMAND_GETS . self::COMMAND_SEPARATOR   .
            $keys                  . self::COMMAND_TERMINATOR;

        $result = $this->send(self::COMMAND_GETS, $data);

        // Strip all overhead if no metadata requested!
        if ($metadata === false) {
            $result = array_column($result, 'value', 'key');
        }

        return $result;
    }
public function gets(array $keys, $metadata = false)
    {
        /**
         * gets <key>*\r\n
         */

        // Build key request string
        $keys = implode(self::COMMAND_SEPARATOR, $keys);

        // Build packet to send ...
        $data = self::COMMAND_GETS . self::COMMAND_SEPARATOR   .
            $keys                  . self::COMMAND_TERMINATOR;

        $result = $this->send(self::COMMAND_GETS, $data);

        // Strip all overhead if no metadata requested!
        if ($metadata === false) {
            $result = array_column($result, 'value', 'key');
        }

        return $result;
    }
public function gets ( array $ keys , $ metadata = false ) { /**
         * gets <key>*\r\n
         */ // Build key request string $ keys = implode ( self :: COMMAND_SEPARATOR , $ keys ) ; // Build packet to send ... $ data = self :: COMMAND_GETS . self :: COMMAND_SEPARATOR . $ keys . self :: COMMAND_TERMINATOR ; $ result = $ this -> send ( self :: COMMAND_GETS , $ data ) ; // Strip all overhead if no metadata requested! if ( $ metadata === false ) { $ result = array_column ( $ result , 'value' , 'key' ) ; } return $ result ; }
Returns the response for passed keys.

@param array $keys     The keys to return response for.
@param bool  $metadata TRUE to return metadata like lifetime ... as well, FALSE to return value only

@author Benjamin Carl <opensource@clickalicious.de>
@return mixed The response for command get
@access public
Returns the response for passed keys .