DbConnectionDispatcher.GetState(DbConnection, DbInterceptionContext) 方法
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
public virtual System.Data.ConnectionState GetState (System.Data.Common.DbConnection connection, System.Data.Entity.Infrastructure.Interception.DbInterceptionContext interceptionContext);
abstract member GetState : System.Data.Common.DbConnection * System.Data.Entity.Infrastructure.Interception.DbInterceptionContext -> System.Data.ConnectionState
override this.GetState : System.Data.Common.DbConnection * System.Data.Entity.Infrastructure.Interception.DbInterceptionContext -> System.Data.ConnectionState
Public Overridable Function GetState (connection As DbConnection, interceptionContext As DbInterceptionContext) As ConnectionState
参数
- connection
- DbConnection
将对其执行操作的连接。
- interceptionContext
- DbInterceptionContext
有关进行调用的上下文的可选信息。
返回
操作的结果,可能已被侦听器修改。
注解
请注意,此属性的值由此方法返回。 结果在传递到此方法的拦截上下文中不可用,因为拦截上下文在传递给侦听器之前是克隆的。