public function buildGuzzleRequest(RequestInterface $request)
    {
        $this->addCallable(function () use ($request) {
            return $this->buildForVersionThree($request);
        });

        $this->addCallable(function () use ($request) {
            return $this->buildForVersionFourOrFive($request);
        });

        $this->addCallable(function () use ($request) {
            return $this->buildForVersionSix($request);
        });

        $guzzleRequest = $this->executeCallableChain();

        if (null === $guzzleRequest) {
            throw new RequestException('Unknown Guzzle client, request instance can not be created.');
        }

        return $guzzleRequest;
    }
public function buildGuzzleRequest(RequestInterface $request)
    {
        $this->addCallable(function () use ($request) {
            return $this->buildForVersionThree($request);
        });

        $this->addCallable(function () use ($request) {
            return $this->buildForVersionFourOrFive($request);
        });

        $this->addCallable(function () use ($request) {
            return $this->buildForVersionSix($request);
        });

        $guzzleRequest = $this->executeCallableChain();

        if (null === $guzzleRequest) {
            throw new RequestException('Unknown Guzzle client, request instance can not be created.');
        }

        return $guzzleRequest;
    }
public function buildGuzzleRequest ( RequestInterface $ request ) { $ this -> addCallable ( function ( ) use ( $ request ) { return $ this -> buildForVersionThree ( $ request ) ; } ) ; $ this -> addCallable ( function ( ) use ( $ request ) { return $ this -> buildForVersionFourOrFive ( $ request ) ; } ) ; $ this -> addCallable ( function ( ) use ( $ request ) { return $ this -> buildForVersionSix ( $ request ) ; } ) ; $ guzzleRequest = $ this -> executeCallableChain ( ) ; if ( null === $ guzzleRequest ) { throw new RequestException ( 'Unknown Guzzle client, request instance can not be created.' ) ; } return $ guzzleRequest ; }
Build guzzle request based on Guzzle client version.

@param RequestInterface $request
@return mixed
@throws RequestException
Build guzzle request based on Guzzle client version .