src/Server/AmazonServer.php
protected function buildRequest(
        string $method,
        BucketInterface $bucket,
        string $name,
        array $headers = [],
        array $commands = []
    ): RequestInterface {
        $headers += [
            'Date'         => gmdate('D, d M Y H:i:s T'),
            'Content-MD5'  => '',
            'Content-Type' => ''
        ];

        $packedCommands = $this->packCommands($commands);

        return $this->signRequest(
            new Request($method, $this->buildUri($bucket, $name), $headers + $packedCommands),
            $packedCommands
        );
    }
protected function buildRequest(
        string $method,
        BucketInterface $bucket,
        string $name,
        array $headers = [],
        array $commands = []
    ): RequestInterface {
        $headers += [
            'Date'         => gmdate('D, d M Y H:i:s T'),
            'Content-MD5'  => '',
            'Content-Type' => ''
        ];

        $packedCommands = $this->packCommands($commands);

        return $this->signRequest(
            new Request($method, $this->buildUri($bucket, $name), $headers + $packedCommands),
            $packedCommands
        );
    }
protected function buildRequest ( string $ method , BucketInterface $ bucket , string $ name , array $ headers = [ ] , array $ commands = [ ] ) : RequestInterface { $ headers += [ 'Date' => gmdate ( 'D, d M Y H:i:s T' ) , 'Content-MD5' => '' , 'Content-Type' => '' ] ; $ packedCommands = $ this -> packCommands ( $ commands ) ; return $ this -> signRequest ( new Request ( $ method , $ this -> buildUri ( $ bucket , $ name ) , $ headers + $ packedCommands ) , $ packedCommands ) ; }
Helper to create configured PSR7 request with set of amazon commands.

@param string          $method
@param BucketInterface $bucket
@param string          $name
@param array           $headers
@param array           $commands Amazon commands associated with values.

@return RequestInterface
Helper to create configured PSR7 request with set of amazon commands .