示例#1
0
 /**
  * {@inheritdoc}
  */
 public function keys()
 {
     try {
         return $this->client->bucket($this->bucketName)->getKeys();
     } catch (Exception $e) {
         throw ReadException::forException($e);
     }
 }
 public static function setUpBeforeClass()
 {
     parent::setUpBeforeClass();
     $client = new Riak();
     self::$supported = $client->isAlive();
 }
 public function testHasKey()
 {
     $client = new Riak(self::HOST, self::PORT);
     $bucket = $client->bucket('bucket');
     $rand = rand();
     $obj = $bucket->newObject('foo', $rand);
     $obj->store();
     $exists = $bucket->hasKey('foo');
     $this->_assert($exists);
 }