語言

DbCommandInterceptionContext.WithCommandBehavior(CommandBehavior) 方法

定義

建立 DbCommandInterceptionContext 一個新 ,包含該攔截上下文中所有上下文資訊,連同給定 CommandBehavior的 。

public System.Data.Entity.Infrastructure.Interception.DbCommandInterceptionContext WithCommandBehavior(System.Data.CommandBehavior commandBehavior);
member this.WithCommandBehavior : System.Data.CommandBehavior -> System.Data.Entity.Infrastructure.Interception.DbCommandInterceptionContext

參數

commandBehavior
CommandBehavior

指令行為要關聯。

傳回

與該指令行為相關的新攔截情境。

適用於