11 lines
240 B
Rust
11 lines
240 B
Rust
use thiserror::Error;
|
|
|
|
#[derive(Debug, Error)]
|
|
pub enum LayerError {}
|
|
|
|
pub trait Layer {
|
|
fn frame(&mut self, data: &mut Vec<u8>) -> Result<bool, LayerError>;
|
|
|
|
fn deframe(&mut self, data: &mut Vec<u8>) -> Result<bool, LayerError>;
|
|
}
|