Grpc\BaseStub::_clientStreamRequest PHP Method

_clientStreamRequest() public method

Call a remote method that takes a stream of arguments and has a single output.
public _clientStreamRequest ( string $method, callable $deserialize, array $metadata = [], $options = [] ) : grpc\ClientStreamingSurfaceActiveCall
$method string The name of the method to call
$deserialize callable A function that deserializes the response
$metadata array A metadata map to send to the server
return grpc\ClientStreamingSurfaceActiveCall The active call object
    public function _clientStreamRequest($method, callable $deserialize, $metadata = [], $options = [])
    {
        $call = new ClientStreamingCall($this->channel, $method, $deserialize, $options);
        $jwt_aud_uri = $this->_get_jwt_aud_uri($method);
        if (is_callable($this->update_metadata)) {
            $metadata = call_user_func($this->update_metadata, $metadata, $jwt_aud_uri);
        }
        $metadata = $this->_validate_and_normalize_metadata($metadata);
        $call->start($metadata);
        return $call;
    }