midix 3.2.0

MIDI structures designed for humans
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#![doc = r#"
Internal debugging utilities
"#]
use crate::prelude::*;

/// Implements traits to handle debugging to stdout
pub struct DebugTarget<T> {
    inner: T,
}

impl<T: MidiTarget> MidiTarget for DebugTarget<T> {
    type Error = T::Error;
    fn handle_event(&mut self, event: MidiMessage) -> Result<(), Self::Error> {
        println!("Handling {:?}", event);
        self.inner.handle_event(event)
    }
}