Expand description
Action logging with pattern-based filtering and in-memory storage
Provides configurable action logging using glob patterns to include/exclude specific actions from logs. Supports both tracing output and in-memory ring buffer storage for display in debug overlays.
§Example
ⓘ
use tui_dispatch_core::debug::{ActionLoggerConfig, ActionLoggerMiddleware, ActionLogConfig};
// Log all actions except Tick and Render (tracing only)
let config = ActionLoggerConfig::default();
let middleware = ActionLoggerMiddleware::new(config);
// Log with in-memory storage for debug overlay display
let config = ActionLogConfig::default();
let middleware = ActionLoggerMiddleware::with_log(config);
// Access the action log
if let Some(log) = middleware.log() {
for entry in log.recent(10) {
println!("{}: {}", entry.elapsed, entry.params);
}
}Structs§
- Action
Log - In-memory ring buffer for storing recent actions
- Action
LogConfig - Configuration for the action log ring buffer
- Action
LogEntry - An entry in the action log
- Action
Logger Config - Configuration for action logging with glob pattern filtering.
- Action
Logger Middleware - Middleware that logs actions with configurable pattern filtering.
Functions§
- glob_
match - Simple glob pattern matching supporting
*and?.