$command = (new Command\Builder\FetchCounter($riak)) ->buildLocation($user_name, 'user_visit_count', 'visit_counters') ->build(); $response = $command->execute(); $counter = $response->getCounter();
Наследование: extends Basho\Riak\Command\Builder, implements Basho\Riak\Command\BuilderInterface, use trait Basho\Riak\Command\Builder\LocationTrait
Пример #1
0
 /**
  * Tests validate properly verifies the Location is not there
  *
  * @dataProvider getLocalNodeConnection
  *
  * @param $riak \Basho\Riak
  *
  * @expectedException \Basho\Riak\Command\Builder\Exception
  */
 public function testValidateLocation($riak)
 {
     $builder = new Command\Builder\FetchCounter($riak);
     $builder->buildBucket('some_bucket');
     $builder->build();
 }