Simple filter to match a string in the NDC
Inheritance Hierarchy
log4net.FilterFilterSkeleton
log4net.FilterStringMatchFilter
log4net.FilterPropertyFilter
log4net.FilterNdcFilter
Namespace: log4net.Filter
Assembly: log4net (in log4net.dll) Version: 2.0.8.0-.NET 4.0
Syntax
The NdcFilter type exposes the following members.
Constructors
| Name | Description | |
|---|---|---|
| NdcFilter |
Default constructor
|
Properties
| Name | Description | |
|---|---|---|
| AcceptOnMatch | (Inherited from StringMatchFilter.) | |
| Key |
The key to lookup in the event properties and then match against.
(Inherited from PropertyFilter.) | |
| Next |
Property to get and set the next filter
(Inherited from FilterSkeleton.) | |
| RegexToMatch |
Sets the regular expression to match
(Inherited from StringMatchFilter.) | |
| StringToMatch |
Sets the static string to match
(Inherited from StringMatchFilter.) |
Methods
| Name | Description | |
|---|---|---|
| ActivateOptions |
Initialize and precompile the Regex if required
(Inherited from StringMatchFilter.) | |
| Decide |
Check if this filter should allow the event to be logged
(Inherited from PropertyFilter.) | |
| Equals | (Inherited from Object.) | |
| Finalize |
Allows an Object to attempt to free resources and perform other cleanup operations before the Object is reclaimed by garbage collection.
(Inherited from Object.) | |
| GetHashCode |
Serves as a hash function for a particular type.
(Inherited from Object.) | |
| GetType |
Gets the Type of the current instance.
(Inherited from Object.) | |
| MemberwiseClone |
Creates a shallow copy of the current Object.
(Inherited from Object.) | |
| ToString | (Inherited from Object.) |
Fields
| Name | Description | |
|---|---|---|
| m_acceptOnMatch |
Flag to indicate the behavior when we have a match
(Inherited from StringMatchFilter.) | |
| m_regexToMatch |
A regex object to match (generated from m_stringRegexToMatch)
(Inherited from StringMatchFilter.) | |
| m_stringRegexToMatch |
A string regex to match
(Inherited from StringMatchFilter.) | |
| m_stringToMatch |
The string to substring match against the message
(Inherited from StringMatchFilter.) |
Remarks
Simple filter to match a string in the NDC
As the MDC has been replaced with named stacks stored in the properties collections the PropertyFilter should be used instead.
See Also