src/S3/MultipartUploader.php
private function decorateWithHashes(Stream $stream, array &$data)
    {
        // Decorate source with a hashing stream
        $hash = new PhpHash('sha256');
        return new HashingStream($stream, $hash, function ($result) use (&$data) {
            $data['ContentSHA256'] = bin2hex($result);
        });
    }
private function decorateWithHashes(Stream $stream, array &$data)
    {
        // Decorate source with a hashing stream
        $hash = new PhpHash('sha256');
        return new HashingStream($stream, $hash, function ($result) use (&$data) {
            $data['ContentSHA256'] = bin2hex($result);
        });
    }
private function decorateWithHashes ( Stream $ stream , array & $ data ) { // Decorate source with a hashing stream $ hash = new PhpHash ( 'sha256' ) ; return new HashingStream ( $ stream , $ hash , function ( $ result ) use ( & $ data ) { $ data [ 'ContentSHA256' ] = bin2hex ( $ result ) ; } ) ; }
Decorates a stream with a sha256 linear hashing stream.

@param Stream $stream Stream to decorate.
@param array  $data   Part data to augment with the hash result.

@return Stream
Decorates a stream with a sha256 linear hashing stream .