GrpcServiceBase
Assembly: ServiceStack.Extensions.dll
View Source
Declaration
public abstract class GrpcServiceBase : IGrpcService
Properties
RpcGateway
View Source
Declaration
protected RpcGateway RpcGateway { get; }
Feature
View Source
Declaration
protected GrpcFeature Feature { get; }
Methods
WriteResponseHeadersAsync(IResponse, CallContext)
View Source
Declaration
protected async Task WriteResponseHeadersAsync(IResponse httpRes, CallContext context)
Returns
Task
Parameters
Type | Name |
---|---|
ServiceStack.Web.IResponse | httpRes |
CallContext | context |
ExecuteDynamic<TResponse>(String, DynamicRequest, CallContext, Type)
View Source
Declaration
protected virtual Task<TResponse> ExecuteDynamic<TResponse>(string method, DynamicRequest request, CallContext context, Type requestType)
Returns
Task<<TResponse>>
Parameters
Type | Name |
---|---|
System.String | method |
ServiceStack.DynamicRequest | request |
CallContext | context |
Type | requestType |
Type Parameters
TResponse
Execute<TResponse>(String, Object, CallContext)
View Source
Declaration
protected virtual async Task<TResponse> Execute<TResponse>(string method, object request, CallContext context)
Returns
Task<<TResponse>>
Parameters
Type | Name |
---|---|
System.String | method |
System.Object | request |
CallContext | context |
Type Parameters
TResponse
PopulateRequestFromHeaders(Object, Grpc.Core.Metadata)
View Source
Declaration
protected virtual void PopulateRequestFromHeaders(object request, Grpc.Core.Metadata headers)
Parameters
Type | Name |
---|---|
System.Object | request |
Grpc.Core.Metadata | headers |
Stream<TRequest, TResponse>(TRequest, CallContext)
View Source
Declaration
protected virtual async IAsyncEnumerable<TResponse> Stream<TRequest, TResponse>(TRequest request, CallContext context)
Returns
IAsyncEnumerable<<TResponse>>
Parameters
Type | Name |
---|---|
<TRequest> | request |
CallContext | context |
Type Parameters
TRequest
TResponse
StreamService<TRequest, TResponse>(IStreamService<TRequest, TResponse>, TRequest, CancellationToken)
View Source
Declaration
protected virtual async IAsyncEnumerable<TResponse> StreamService<TRequest, TResponse>(IStreamService<TRequest, TResponse> service, TRequest request, CancellationToken cancel)
Returns
IAsyncEnumerable<<TResponse>>
Parameters
Type | Name |
---|---|
ServiceStack.IStreamService<<TRequest>,<TResponse>> | service |
<TRequest> | request |
CancellationToken | cancel |
Type Parameters
TRequest
TResponse
ToGrpcStatus(Int32, String)
View Source
Declaration
protected Status ToGrpcStatus(int httpStatus, string detail)
Returns
Status
Parameters
Type | Name |
---|---|
System.Int32 | httpStatus |
System.String | detail |