共用方式為


RelationalOptionsExtension.WithExecutionStrategyFactory 方法

定義

建立與這個實例相同的所有選項的新實例,但指定選項已變更。 直接呼叫這個方法並不尋常。 請改用 DbContextOptionsBuilder

public virtual Microsoft.EntityFrameworkCore.Infrastructure.RelationalOptionsExtension WithExecutionStrategyFactory (Func<Microsoft.EntityFrameworkCore.Storage.ExecutionStrategyDependencies,Microsoft.EntityFrameworkCore.Storage.IExecutionStrategy> executionStrategyFactory);
public virtual Microsoft.EntityFrameworkCore.Infrastructure.RelationalOptionsExtension WithExecutionStrategyFactory (Func<Microsoft.EntityFrameworkCore.Storage.ExecutionStrategyDependencies,Microsoft.EntityFrameworkCore.Storage.IExecutionStrategy>? executionStrategyFactory);
abstract member WithExecutionStrategyFactory : Func<Microsoft.EntityFrameworkCore.Storage.ExecutionStrategyDependencies, Microsoft.EntityFrameworkCore.Storage.IExecutionStrategy> -> Microsoft.EntityFrameworkCore.Infrastructure.RelationalOptionsExtension
override this.WithExecutionStrategyFactory : Func<Microsoft.EntityFrameworkCore.Storage.ExecutionStrategyDependencies, Microsoft.EntityFrameworkCore.Storage.IExecutionStrategy> -> Microsoft.EntityFrameworkCore.Infrastructure.RelationalOptionsExtension
Public Overridable Function WithExecutionStrategyFactory (executionStrategyFactory As Func(Of ExecutionStrategyDependencies, IExecutionStrategy)) As RelationalOptionsExtension

參數

executionStrategyFactory
Func<ExecutionStrategyDependencies,IExecutionStrategy>

要變更的選項。

傳回

選項已變更的新實例。

適用於