Struct tokio_http2::http::HttpCodec
[−]
[src]
pub struct HttpCodec { /* fields omitted */ }
Trait Implementations
impl Codec for HttpCodec
[src]
type In = Request
The type of decoded frames.
type Out = Response
The type of frames to be encoded.
fn decode(&mut self, buf: &mut EasyBuf) -> Result<Option<Request>>
HttpCodec::decode can be modified to fit whatever is needed.
fn encode(&mut self, msg: Response, buf: &mut Vec<u8>) -> Result<()>
Encodes a frame into the buffer provided. Read more
fn decode_eof(&mut self, buf: &mut EasyBuf) -> Result<Self::In, Error>
A default method available to be called when there are no more bytes available to be read from the underlying I/O. Read more