summaryrefslogtreecommitdiff
path: root/src/protocol/codec.rs
blob: ce3d0a46864f2b62626146b011b43b0bfe097b74 (plain)
1
2
3
4
5
6
7
8
9
10
use nom::IResult;
use std::fmt::Debug;

pub trait Decode<T: Debug> {
    fn decode(input: &[u8]) -> IResult<&[u8], T>;
}

pub trait Encode<T: Debug> {
    // TODO
}