Class
LogFilter
ConsoleMonster.Widgets
Which log entries a log region, log viewport or log tail shows: one source tag, a minimum level and a literal text. Every part that is set must match. Hidden entries stay in the retained history, so changing the filter brings them back.
Inheritance
- object
- LogFilter
Usage
Explore 6 API references to this type
This type appears in these public API surfaces even when no hand-authored example is attached directly to the page.
Returned or exposed by 2
- Property LogViewport.Filter
- Property LogRegion.Filter
Accepted by parameters 4
- Method InteractiveFluent.Filter
- Extension method LogViewport.Filter
- Extension method LogRegion.Filter
- Method WidgetsFluent.Filter
Constructors
public LogFilter(string? tag = null, string? level = null, string? text = null) #Creates a filter; null or empty parts match every entry.
Parameters
- tag string? = null
- The source tag to show, compared without case, or null for every source.
- level string? = null
- The lowest level to show (debug, verbose, info, warn, err; pass and skip rank with info), or null for every level.
- text string? = null
- Literal text the entry must contain, compared without case, or null.
Exceptions
ArgumentException– The level is not a log level or status word.
Methods
public bool Matches(LogEntry entry) #Whether an entry passes the filter.
Parameters
- entry ConsoleMonster.Widgets.LogEntry
- The entry.
Returns
bool True when the entry is shown.