nnrp-runtime 1.0.0-preview.3.2

Transport-neutral NNRP client/server session runtime over framed async transport slots.
Documentation
use thiserror::Error;

#[derive(Debug, Error)]
pub enum RuntimeError {
    #[error("transport I/O failed: {0}")]
    Io(#[from] std::io::Error),

    #[error("protocol validation failed: {0}")]
    Protocol(#[from] nnrp_core::NnrpError),

    #[error("unsupported transport: {0}")]
    UnsupportedTransport(&'static str),

    #[error("frame id overflowed")]
    FrameIdOverflow,

    #[error("unexpected runtime message: {0}")]
    UnexpectedMessage(&'static str),

    #[error("runtime internal error: {0}")]
    Internal(&'static str),
}