Build a Bucket Key Map-Reduce command object

@return \Riak\Client\Command\MapReduce\Input\BucketKeyInput
344521
public function build()
    {
        $input = new BucketKeyInput($this->inputs);
        $spec  = new Specification($input, $this->phases, $this->timeout);

        return new BucketKeyMapReduce($spec);
    }
413430
public function getBuckets()
    {
        if (!isset($this->rawData['buckets'])) {
            return null;
        }

        $buckets = [];

        foreach ($this->rawData['buckets'] as $bucket) {
            $buckets[] = new self($bucket);
        }

        return $buckets;
    }
1152582
private function getS3Bucket()
    {
        $settings = $this->getSettings();

        $bucket = S3Bucket::getInstance(
            $settings->bucketRegion,
            $settings->bucketName,
            $settings->awsKey,
            $settings->awsSecret
        );

        return $bucket;
    }
1353108
public function getObjectAcl($bucket, $key)
    {
        $params = [
            'Bucket' => $bucket,
            'Key'    => $key
        ];

        return $this->instance->getObjectAcl($params);
    }
810410
public function generateRandomApiKey()
    {
        $this->_api_key_private = md5($this->_id . uniqid());

        $this->_api_key_public = $this->generateApiPublicKey();

        return $this;
    }
1121750
public function reduce(...$keys)
    {
        $keys = $this->normalizeKeys($keys);

        foreach ($this->keys() as $key) {
            if (!in_array($key, $keys, true)) {
                $this->remove($key);
            }
        }

        return $this;
    }
224069
public function buildCommand()
    {
        $command = $this->command . ' >> ' . $this->_output . ' 2>&1 &';

        return $this->_user ? 'sudo -u ' . $this->_user . ' ' . $command : $command;
    }
1208323
public static function build()
    {
        switch (true) {
            // @codeCoverageIgnoreStart
            case extension_loaded('apc'):
                $cacheDriver = new ApcuCache;
                break;

            case extension_loaded('xcache'):
                $cacheDriver = new XcacheCache;
                break;

            case extension_loaded('memcache'):
                $memcache = new \Memcache;
                $memcache->connect('127.0.0.1');

                $cacheDriver = new MemcacheCache;
                $cacheDriver->setMemcache($memcache);
                break;

            case extension_loaded('redis'):
                $redis = new \Redis();
                $redis->connect('127.0.0.1');

                $cacheDriver = new RedisCache;
                $cacheDriver->setRedis($redis);
                break;
            // @codeCoverageIgnoreEnd

            default:
                $cacheDriver = new ArrayCache;
        }

        return $cacheDriver;
    }
572036
public function buildCommand()
	{
		if ($this->withoutOverlapping)
		{
			$command = '(touch '.$this->mutexPath().'; '.$this->command.'; rm '.$this->mutexPath().') > '.$this->output.' 2>&1 &';
		}
		else
		{
			$command = $this->command.' > '.$this->output.' 2>&1 &';
		}


		return $this->user ? 'sudo -u '.$this->user.' '.$command : $command;
	}
328224
protected function _buildCommand()
    {
        $command = $this->_binary;
        $options = (array)$this->getConfig('options');
        foreach ($options as $key => $value) {
            if (empty($value)) {
                continue;
            } elseif ($value === true) {
                $command .= ' --' . $key;
            } else {
                $command .= sprintf(' --%s %s', $key, escapeshellarg($value));
            }
        }

        return $command;
    }
1198654
protected function getKeyFile()
    {
        return $this->files->exists('.env') ? $this->files->get('.env') : $this->files->get('.env.example');
    }
401045
public function keys()
    {
        return $this->create(array_keys($this->toArray()))->map(
            function ($key) {
                return new String($key);
            }
        );
    }
422659
public function doGetKey()
    {
        foreach ($this->data as $key => $value) {
            if ($this->value === $value) {
                return $key;
            }
        }

        return $this->default;
    }
516800
public function build()
    {
        $input = new IndexInput($this->namespace, $this->indexName, $this->criteria);
        $spec  = new Specification($input, $this->phases, $this->timeout);

        return new IndexMapReduce($spec);
    }
1110771
public function build()
    {
        $input = new SearchInput($this->index, $this->query);
        $spec  = new Specification($input, $this->phases, $this->timeout);

        return new SearchMapReduce($spec);
    }
805877
private function buildPipeline()
    {
        $nextCallable = function ($item) {
            // the final callable is a no-op
        };

        foreach ($this->getStepsSortedDescByPriority() as $step) {
            $nextCallable = function ($item) use ($step, $nextCallable) {
                return $step->process($item, $nextCallable);
            };
        }

        return $nextCallable;
    }
1308882
protected function createRedisDriver()
    {
        $handler = $this->createCacheHandler('redis');

        $handler->getCache()->getStore()->setConnection(
            $this->app['config']['session.connection']
        );

        return $this->buildSession($handler);
    }