共用方式為


ISiloHostBuilder.ConfigureServices 方法

定義

將服務新增至容器。 這可以呼叫多次,結果會進行累加。

public Orleans.Hosting.ISiloHostBuilder ConfigureServices (Action<Orleans.Hosting.HostBuilderContext,Microsoft.Extensions.DependencyInjection.IServiceCollection> configureDelegate);
abstract member ConfigureServices : Action<Orleans.Hosting.HostBuilderContext, Microsoft.Extensions.DependencyInjection.IServiceCollection> -> Orleans.Hosting.ISiloHostBuilder
Public Function ConfigureServices (configureDelegate As Action(Of HostBuilderContext, IServiceCollection)) As ISiloHostBuilder

參數

configureDelegate
Action<HostBuilderContext,IServiceCollection>

此委派可設定將用來建構 IServiceProviderIServiceCollection

傳回

用於鏈結之主機產生器的相同實例。

適用於