Class DefaultCallInvoker

public class DefaultCallInvoker : CallInvoker

Invokes client RPCs using Calls.

Inheritance

Object > CallInvoker > DefaultCallInvoker

Namespace

Grpc.Core

Assembly

Grpc.Core.dll

Constructors

DefaultCallInvoker(Channel)

public DefaultCallInvoker(Channel channel)

Initializes a new instance of the DefaultCallInvoker class.

Parameter
TypeNameDescription
Channelchannel

Channel to use.

Methods

AsyncClientStreamingCall<TRequest, TResponse>(Method<TRequest, TResponse>, String, CallOptions)

public override AsyncClientStreamingCall<TRequest, TResponse> AsyncClientStreamingCall<TRequest, TResponse>(Method<TRequest, TResponse> method, string host, CallOptions options)

Invokes a client streaming call asynchronously. In client streaming scenario, client sends a stream of requests and server responds with a single response.

Parameters
TypeNameDescription
Method<TRequest, TResponse>method
Stringhost
CallOptionsoptions
Returns
TypeDescription
AsyncClientStreamingCall<TRequest, TResponse>
Type Parameters
NameDescription
TRequest
TResponse

AsyncDuplexStreamingCall<TRequest, TResponse>(Method<TRequest, TResponse>, String, CallOptions)

public override AsyncDuplexStreamingCall<TRequest, TResponse> AsyncDuplexStreamingCall<TRequest, TResponse>(Method<TRequest, TResponse> method, string host, CallOptions options)

Invokes a duplex streaming call asynchronously. In duplex streaming scenario, client sends a stream of requests and server responds with a stream of responses. The response stream is completely independent and both side can be sending messages at the same time.

Parameters
TypeNameDescription
Method<TRequest, TResponse>method
Stringhost
CallOptionsoptions
Returns
TypeDescription
AsyncDuplexStreamingCall<TRequest, TResponse>
Type Parameters
NameDescription
TRequest
TResponse

AsyncServerStreamingCall<TRequest, TResponse>(Method<TRequest, TResponse>, String, CallOptions, TRequest)

public override AsyncServerStreamingCall<TResponse> AsyncServerStreamingCall<TRequest, TResponse>(Method<TRequest, TResponse> method, string host, CallOptions options, TRequest request)

Invokes a server streaming call asynchronously. In server streaming scenario, client sends on request and server responds with a stream of responses.

Parameters
TypeNameDescription
Method<TRequest, TResponse>method
Stringhost
CallOptionsoptions
TRequestrequest
Returns
TypeDescription
AsyncServerStreamingCall<TResponse>
Type Parameters
NameDescription
TRequest
TResponse

AsyncUnaryCall<TRequest, TResponse>(Method<TRequest, TResponse>, String, CallOptions, TRequest)

public override AsyncUnaryCall<TResponse> AsyncUnaryCall<TRequest, TResponse>(Method<TRequest, TResponse> method, string host, CallOptions options, TRequest request)

Invokes a simple remote call asynchronously.

Parameters
TypeNameDescription
Method<TRequest, TResponse>method
Stringhost
CallOptionsoptions
TRequestrequest
Returns
TypeDescription
AsyncUnaryCall<TResponse>
Type Parameters
NameDescription
TRequest
TResponse

BlockingUnaryCall<TRequest, TResponse>(Method<TRequest, TResponse>, String, CallOptions, TRequest)

public override TResponse BlockingUnaryCall<TRequest, TResponse>(Method<TRequest, TResponse> method, string host, CallOptions options, TRequest request)

Invokes a simple remote call in a blocking fashion.

Parameters
TypeNameDescription
Method<TRequest, TResponse>method
Stringhost
CallOptionsoptions
TRequestrequest
Returns
TypeDescription
TResponse
Type Parameters
NameDescription
TRequest
TResponse

CreateCall<TRequest, TResponse>(Method<TRequest, TResponse>, String, CallOptions)

protected virtual CallInvocationDetails<TRequest, TResponse> CreateCall<TRequest, TResponse>(Method<TRequest, TResponse> method, string host, CallOptions options)
    where TRequest : class where TResponse : class

Creates call invocation details for given method.

Parameters
TypeNameDescription
Method<TRequest, TResponse>method
Stringhost
CallOptionsoptions
Returns
TypeDescription
CallInvocationDetails<TRequest, TResponse>
Type Parameters
NameDescription
TRequest
TResponse