pub struct UcPack { /* private fields */ }Expand description
UcPack structure
Implementations§
Source§impl UcPack
impl UcPack
pub const fn new(start_index: u8, end_index: u8) -> Self
pub fn serialize_vec( &self, payload: &impl Serialize, ) -> Result<Vec<u8>, UcPackError>
pub fn serialize_slice( &self, payload: &impl Serialize, buffer: &mut [u8], ) -> Result<usize, UcPackError>
pub fn deserialize_slice<'d, 'b, T>(
&self,
buffer: &'b [u8],
) -> Result<T, UcPackError>where
T: Deserialize<'d>,
'b: 'd,
Trait Implementations§
Auto Trait Implementations§
impl Freeze for UcPack
impl RefUnwindSafe for UcPack
impl Send for UcPack
impl Sync for UcPack
impl Unpin for UcPack
impl UnwindSafe for UcPack
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more