public static class ServiceCollectionExtensionsReference documentation and code samples for the Maintenance v1beta API class ServiceCollectionExtensions.
Static class to provide extension methods to configure API clients.
Namespace
Microsoft.Extensions.DependencyInjectionAssembly
Google.Cloud.Maintenance.Api.V1Beta.dll
Methods
AddMaintenanceClient(IServiceCollection, Action<MaintenanceClientBuilder>)
public static IServiceCollection AddMaintenanceClient(this IServiceCollection services, Action<MaintenanceClientBuilder> action = null)Adds a singleton MaintenanceClient to services.
| Parameters | |
|---|---|
| Name | Description |
services |
IServiceCollectionThe service collection to add the client to. The services are used to configure the client when requested. |
action |
ActionMaintenanceClientBuilderAn optional action to invoke on the client builder. This is invoked before services from
|
| Returns | |
|---|---|
| Type | Description |
IServiceCollection |
|
AddMaintenanceClient(IServiceCollection, Action<IServiceProvider, MaintenanceClientBuilder>)
public static IServiceCollection AddMaintenanceClient(this IServiceCollection services, Action<IServiceProvider, MaintenanceClientBuilder> action)Adds a singleton MaintenanceClient to services.
| Parameters | |
|---|---|
| Name | Description |
services |
IServiceCollectionThe service collection to add the client to. The services are used to configure the client when requested. |
action |
ActionSystem.IServiceProviderMaintenanceClientBuilderAn optional action to invoke on the client builder. This is invoked before services from
|
| Returns | |
|---|---|
| Type | Description |
IServiceCollection |
|