PHP Class Basho\Riak\Command\Builder

use Basho\Riak\Command; use Basho\Riak\Bucket; use Basho\Riak\Location; $bucket = new Bucket('users'); $command = (new Command\Builder(Command::STORE_OBJECT)) ->withObject(new Object('test_data')) ->atLocation(new Location('test_key', $bucket)) ->build();
Afficher le fichier Open project: basho/riak-php-client Class Usage Examples

Protected Properties

Свойство Type Description
$headers array Command request headers
$parameters array Command parameters
$riak Basho\Riak | null
$verbose

Méthodes publiques

Méthode Description
__construct ( Riak $riak )
build ( ) Command build
getConnection ( )
getParameters ( )
getVerbose ( )
withParameter ( $key, $value = true )
withParameters ( $parameters = [] )
withVerboseMode ( $verbose = true )

Méthodes protégées

Méthode Description
required ( $objectName ) Used to verify a property within the builder is not null and is instantiated
validate ( ) : boolean Validate command

Method Details

__construct() public méthode

public __construct ( Riak $riak )
$riak Basho\Riak

build() abstract public méthode

Validates then returns the built command object.
abstract public build ( )

getConnection() public méthode

public getConnection ( )

getParameters() public méthode

public getParameters ( )

getVerbose() public méthode

public getVerbose ( )

required() protected méthode

Used to verify a property within the builder is not null and is instantiated
protected required ( $objectName )
$objectName

validate() protected méthode

Method validates if the builder has the parameters / objects required to successfully execute the command
protected validate ( ) : boolean
Résultat boolean

withParameter() public méthode

public withParameter ( $key, $value = true )

withParameters() public méthode

public withParameters ( $parameters = [] )

withVerboseMode() public méthode

public withVerboseMode ( $verbose = true )

Property Details

$headers protected_oe property

Command request headers
protected array $headers
Résultat array

$parameters protected_oe property

Command parameters
protected array $parameters
Résultat array

$riak protected_oe property

protected Riak,Basho|null $riak
Résultat Basho\Riak | null

$verbose protected_oe property

protected $verbose