pub mod codec;
pub mod compression;
pub mod state;
pub mod transport;
pub use codec::MottoCodec;
pub use compression::ZstdCompressor;
pub use state::StateMachine;
pub use transport::WebTransportClient;
pub struct MottoRuntime {
pub codec: MottoCodec,
pub compressor: ZstdCompressor,
}
impl MottoRuntime {
pub fn new() -> Self {
Self {
codec: MottoCodec::new(),
compressor: ZstdCompressor::new(3),
}
}
pub fn with_compression_level(level: i32) -> Self {
Self {
codec: MottoCodec::new(),
compressor: ZstdCompressor::new(level),
}
}
}
impl Default for MottoRuntime {
fn default() -> Self {
Self::new()
}
}