C# Class Aspectacular.SqlCmdExecutionPlanAspect

Logs T-SQL execution plan of a SqlCommand.
Inheritance: Aspect
Datei anzeigen Open project: vgribok/Aspectacular

Protected Properties

Property Type Description
cmdRetriever SqlCommand>.Func
command System.Data.SqlClient.SqlCommand

Public Methods

Method Description
SqlCmdExecutionPlanAspect ( SqlCommand>.Func cmdFetcher = null, bool trueText_falseXml = false ) : System

Aspect that log SQL Execution plan of a SqlCommand.

SqlCmdExecutionPlanAspect ( string formatXmlOrText ) : System

Aspect that log SQL Execution plan of an intercepted SqlCommand.

Step_2_BeforeTryingMethodExec ( ) : void

Protected Methods

Method Description
ProcessExecutionPlan ( string executionPlan ) : void

Do something with the execution plan. Default action is to log it.

Private Methods

Method Description
OnConnectionOpened ( ) : void
OnConnectionStateChange ( object sender, StateChangeEventArgs e ) : void

Method Details

ProcessExecutionPlan() protected method

Do something with the execution plan. Default action is to log it.
protected ProcessExecutionPlan ( string executionPlan ) : void
executionPlan string
return void

SqlCmdExecutionPlanAspect() public method

Aspect that log SQL Execution plan of a SqlCommand.
public SqlCmdExecutionPlanAspect ( SqlCommand>.Func cmdFetcher = null, bool trueText_falseXml = false ) : System
cmdFetcher SqlCommand>.Func Optional SqlCommand factory. If not specified, intercepted object should be SqlCommand.
trueText_falseXml bool Specifies output format of the execution plan text: plain text or XML.
return System

SqlCmdExecutionPlanAspect() public method

Aspect that log SQL Execution plan of an intercepted SqlCommand.
public SqlCmdExecutionPlanAspect ( string formatXmlOrText ) : System
formatXmlOrText string /// string in the format of "format=text;" or "format=xml;". /// If not specified, XML format is used. ///
return System

Step_2_BeforeTryingMethodExec() public method

public Step_2_BeforeTryingMethodExec ( ) : void
return void

Property Details

cmdRetriever protected_oe property

protected Func cmdRetriever
return SqlCommand>.Func

command protected_oe property

protected SqlCommand,System.Data.SqlClient command
return System.Data.SqlClient.SqlCommand