ProfilerFilter is the abstract base class for all filters for the Linq-to-SQL Profiler. Inherit this class to implement a new filter. Filters that rely on SQL Server execution plan data for evaluating filter conditions should be marked with the UsesExecutionPlanDataAttribute attribute.
Namespace: Huagati.LinqToSQL.Profiler.FiltersAssembly: HuagatiL2SProfiler (in HuagatiL2SProfiler.dll) Version: 1.33.3996.16059
Syntax
C# |
---|
public abstract class ProfilerFilter |
Visual Basic |
---|
Public MustInherit Class ProfilerFilter |
Visual C++ |
---|
public ref class ProfilerFilter abstract |
Examples
The following example shows how to implement a custom filter for use with the Linq-to-SQL Profiler.
CopyC#
public class MyCustomFilter : ProfilerFilter { public override bool IsValid(QueryInformation query) { //if the query reads more than 1Mb of table data, or more than 1Mb of LOBs, include in the profiler log if (query.TotalReadsKilobytes > 1024 || query.TotalLOBReadsKilobytes > 1024) { return true; } else { return false; } } }
Inheritance Hierarchy
System..::..Object
Huagati.LinqToSQL.Profiler.Filters..::..ProfilerFilter
Huagati.LinqToSQL.Profiler.Filters..::..ExecutionTimeAndPageReadsFilter
Huagati.LinqToSQL.Profiler.Filters..::..ExecutionTimeFilter
Huagati.LinqToSQL.Profiler.Filters..::..InfoMessageFilter
Huagati.LinqToSQL.Profiler.Filters..::..MissingIndexFilter
Huagati.LinqToSQL.Profiler.Filters..::..NullFilter
Huagati.LinqToSQL.Profiler.Filters..::..PageReadFilter
Huagati.LinqToSQL.Profiler.Filters..::..PageReadsPerSecondFilter
Huagati.LinqToSQL.Profiler.Filters..::..PrePlanPostPlanFilter
Huagati.LinqToSQL.Profiler.Filters..::..ProfilerFilterDisabled
Huagati.LinqToSQL.Profiler.Filters..::..TableFilter
Huagati.LinqToSQL.Profiler.Filters..::..TableScanFilter
Huagati.LinqToSQL.Profiler.Filters..::..ProfilerFilter
Huagati.LinqToSQL.Profiler.Filters..::..ExecutionTimeAndPageReadsFilter
Huagati.LinqToSQL.Profiler.Filters..::..ExecutionTimeFilter
Huagati.LinqToSQL.Profiler.Filters..::..InfoMessageFilter
Huagati.LinqToSQL.Profiler.Filters..::..MissingIndexFilter
Huagati.LinqToSQL.Profiler.Filters..::..NullFilter
Huagati.LinqToSQL.Profiler.Filters..::..PageReadFilter
Huagati.LinqToSQL.Profiler.Filters..::..PageReadsPerSecondFilter
Huagati.LinqToSQL.Profiler.Filters..::..PrePlanPostPlanFilter
Huagati.LinqToSQL.Profiler.Filters..::..ProfilerFilterDisabled
Huagati.LinqToSQL.Profiler.Filters..::..TableFilter
Huagati.LinqToSQL.Profiler.Filters..::..TableScanFilter