From 1bed4eb5a3727e84bac4d64995df212a971f4566 Mon Sep 17 00:00:00 2001 From: Max Audron Date: Wed, 26 Feb 2025 18:23:55 +0100 Subject: refactor deserialize and serializevariant trait move stuff around a bit to sepperate it out for deserializevariant --- src/deserialize.rs | 21 --------------------- 1 file changed, 21 deletions(-) delete mode 100644 src/deserialize.rs (limited to 'src/deserialize.rs') diff --git a/src/deserialize.rs b/src/deserialize.rs deleted file mode 100644 index e13f21f..0000000 --- a/src/deserialize.rs +++ /dev/null @@ -1,21 +0,0 @@ -use crate::error::ProtocolError; - -/// Deserialization of types and structs to the quassel byteprotocol -pub trait Deserialize { - fn parse(b: &[u8]) -> Result<(usize, Self), ProtocolError> - where - Self: std::marker::Sized; -} - -/// Deserialization of UTF-8 based Strings to the quassel byteprotocol -pub trait DeserializeUTF8 { - fn parse_utf8(b: &[u8]) -> Result<(usize, Self), ProtocolError> - where - Self: std::marker::Sized; -} - -pub trait DeserializeVariant { - fn parse_variant(b: &[u8]) -> Result<(usize, Self), ProtocolError> - where - Self: std::marker::Sized; -} -- cgit v1.2.3