Class ServiceCollectionExtensions
Static class to provide extension methods to configure API clients.
Namespace: Microsoft.Extensions.DependencyInjection
Assembly: Google.Apps.Chat.V1.dll
Syntax
public static class ServiceCollectionExtensions
Methods
AddChatServiceClient(IServiceCollection, Action<ChatServiceClientBuilder>)
Adds a singleton ChatServiceClient to services.
Declaration
public static IServiceCollection AddChatServiceClient(this IServiceCollection services, Action<ChatServiceClientBuilder> action = null)
Parameters
| Type | Name | Description |
|---|---|---|
| IServiceCollection | services | The service collection to add the client to. The services are used to configure the client when requested. |
| Action<ChatServiceClientBuilder> | action | An optional action to invoke on the client builder. This is invoked before services from
|
Returns
| Type | Description |
|---|---|
| IServiceCollection |
AddChatServiceClient(IServiceCollection, Action<IServiceProvider, ChatServiceClientBuilder>)
Adds a singleton ChatServiceClient to services.
Declaration
public static IServiceCollection AddChatServiceClient(this IServiceCollection services, Action<IServiceProvider, ChatServiceClientBuilder> action)
Parameters
| Type | Name | Description |
|---|---|---|
| IServiceCollection | services | The service collection to add the client to. The services are used to configure the client when requested. |
| Action<IServiceProvider, ChatServiceClientBuilder> | action | An optional action to invoke on the client builder. This is invoked before services from
|
Returns
| Type | Description |
|---|---|
| IServiceCollection |