你当前正在访问 Microsoft Azure Global Edition 技术文档网站。 如果需要访问由世纪互联运营的 Microsoft Azure 中国技术文档网站,请访问 https://docs.azure.cn

AzureClientFactoryBuilder.AddClient 方法

定义

重载

AddClient<TClient,TOptions>(Func<TOptions,TokenCredential,IServiceProvider,TClient>)

添加一个客户端工厂,以便 TClientTOptions 用作选项类型,将 TokenCredential 用于身份验证。 允许在客户端构造期间从 IServiceProvider 解析服务。

AddClient<TClient,TOptions>(Func<TOptions,TokenCredential,TClient>)

添加一个客户端工厂,以便 TClientTOptions 用作选项类型,将 TokenCredential 用于身份验证。

AddClient<TClient,TOptions>(Func<TOptions,IServiceProvider,TClient>)

添加客户端工厂,以便 TClientTOptions 用作选项类型。 允许在客户端构造期间从 IServiceProvider 解析服务。

AddClient<TClient,TOptions>(Func<TOptions,TClient>)

添加客户端工厂,以便 TClientTOptions 用作选项类型。

AddClient<TClient,TOptions>(Func<TOptions,TokenCredential,IServiceProvider,TClient>)

Source:
AzureClientFactoryBuilder.cs

添加一个客户端工厂,以便 TClientTOptions 用作选项类型,将 TokenCredential 用于身份验证。 允许在客户端构造期间从 IServiceProvider 解析服务。

public Azure.Core.Extensions.IAzureClientBuilder<TClient,TOptions> AddClient<TClient,TOptions> (Func<TOptions,Azure.Core.TokenCredential,IServiceProvider,TClient> factory) where TOptions : class;
member this.AddClient : Func<'Options, Azure.Core.TokenCredential, IServiceProvider, 'Client (requires 'Options : null)> -> Azure.Core.Extensions.IAzureClientBuilder<'Client, 'Options (requires 'Options : null)> (requires 'Options : null)
Public Function AddClient(Of TClient, TOptions) (factory As Func(Of TOptions, TokenCredential, IServiceProvider, TClient)) As IAzureClientBuilder(Of TClient, TOptions)

类型参数

TClient

客户端的类型。

TOptions

客户端选项的类型。

参数

factory
Func<TOptions,TokenCredential,IServiceProvider,TClient>

返回

IAzureClientBuilder<TClient,TOptions> 允许客户端配置的 。

适用于

AddClient<TClient,TOptions>(Func<TOptions,TokenCredential,TClient>)

Source:
AzureClientFactoryBuilder.cs

添加一个客户端工厂,以便 TClientTOptions 用作选项类型,将 TokenCredential 用于身份验证。

public Azure.Core.Extensions.IAzureClientBuilder<TClient,TOptions> AddClient<TClient,TOptions> (Func<TOptions,Azure.Core.TokenCredential,TClient> factory) where TOptions : class;
member this.AddClient : Func<'Options, Azure.Core.TokenCredential, 'Client (requires 'Options : null)> -> Azure.Core.Extensions.IAzureClientBuilder<'Client, 'Options (requires 'Options : null)> (requires 'Options : null)
Public Function AddClient(Of TClient, TOptions) (factory As Func(Of TOptions, TokenCredential, TClient)) As IAzureClientBuilder(Of TClient, TOptions)

类型参数

TClient

客户端的类型。

TOptions

客户端选项的类型。

参数

factory
Func<TOptions,TokenCredential,TClient>

返回

IAzureClientBuilder<TClient,TOptions> 允许客户端配置的 。

适用于

AddClient<TClient,TOptions>(Func<TOptions,IServiceProvider,TClient>)

Source:
AzureClientFactoryBuilder.cs

添加客户端工厂,以便 TClientTOptions 用作选项类型。 允许在客户端构造期间从 IServiceProvider 解析服务。

public Azure.Core.Extensions.IAzureClientBuilder<TClient,TOptions> AddClient<TClient,TOptions> (Func<TOptions,IServiceProvider,TClient> factory) where TOptions : class;
member this.AddClient : Func<'Options, IServiceProvider, 'Client (requires 'Options : null)> -> Azure.Core.Extensions.IAzureClientBuilder<'Client, 'Options (requires 'Options : null)> (requires 'Options : null)
Public Function AddClient(Of TClient, TOptions) (factory As Func(Of TOptions, IServiceProvider, TClient)) As IAzureClientBuilder(Of TClient, TOptions)

类型参数

TClient

客户端的类型。

TOptions

客户端选项的类型。

参数

factory
Func<TOptions,IServiceProvider,TClient>

返回

IAzureClientBuilder<TClient,TOptions> 允许客户端配置的 。

适用于

AddClient<TClient,TOptions>(Func<TOptions,TClient>)

Source:
AzureClientFactoryBuilder.cs

添加客户端工厂,以便 TClientTOptions 用作选项类型。

public Azure.Core.Extensions.IAzureClientBuilder<TClient,TOptions> AddClient<TClient,TOptions> (Func<TOptions,TClient> factory) where TOptions : class;
member this.AddClient : Func<'Options, 'Client (requires 'Options : null)> -> Azure.Core.Extensions.IAzureClientBuilder<'Client, 'Options (requires 'Options : null)> (requires 'Options : null)
Public Function AddClient(Of TClient, TOptions) (factory As Func(Of TOptions, TClient)) As IAzureClientBuilder(Of TClient, TOptions)

类型参数

TClient

客户端的类型。

TOptions

客户端选项的类型。

参数

factory
Func<TOptions,TClient>

返回

IAzureClientBuilder<TClient,TOptions> 允许客户端配置的 。

适用于