Skip to content

Class GrpcTransportServiceCollectionExtensions

Namespace: Cephalon.AspNetCore.Grpc.Hosting
Assembly: Cephalon.AspNetCore.Grpc.dll

Registers the gRPC ASP.NET Core transport adapter for Cephalon.

public static class GrpcTransportServiceCollectionExtensions

objectGrpcTransportServiceCollectionExtensions

object.Equals(object?), object.Equals(object?, object?), object.GetHashCode(), object.GetType(), object.MemberwiseClone(), object.ReferenceEquals(object?, object?), object.ToString()

Adds the gRPC transport mapper and ASP.NET Core gRPC services to the service collection.

public static IServiceCollection AddGrpcTransport(this IServiceCollection services)

services IServiceCollection

The target service collection.

IServiceCollection

The same service collection for further registration.

Adds the gRPC transport mapper to a .

public static WebApplicationBuilder AddGrpcTransport(this WebApplicationBuilder builder)

builder WebApplicationBuilder

The ASP.NET Core application builder to extend.

WebApplicationBuilder

The same builder instance for fluent composition.