Struct wrpc_transport::SyncCodec
source · pub struct SyncCodec<T>(pub T);
Expand description
Codec for synchronous values
This is a wrapper struct, which provides a no-op Deferred implementation for any codec.
Tuple Fields§
§0: T
Trait Implementations§
source§impl<T> Decoder for SyncCodec<T>where
T: Decoder,
impl<T> Decoder for SyncCodec<T>where
T: Decoder,
source§fn decode(
&mut self,
src: &mut BytesMut,
) -> Result<Option<Self::Item>, Self::Error>
fn decode( &mut self, src: &mut BytesMut, ) -> Result<Option<Self::Item>, Self::Error>
Attempts to decode a frame from the provided buffer of bytes. Read more
source§impl<T, C> Deferred<T> for SyncCodec<C>
impl<T, C> Deferred<T> for SyncCodec<C>
source§fn take_deferred(&mut self) -> Option<DeferredFn<T>>
fn take_deferred(&mut self) -> Option<DeferredFn<T>>
Takes a deferred async processing operation, if any
Auto Trait Implementations§
impl<T> Freeze for SyncCodec<T>where
T: Freeze,
impl<T> RefUnwindSafe for SyncCodec<T>where
T: RefUnwindSafe,
impl<T> Send for SyncCodec<T>where
T: Send,
impl<T> Sync for SyncCodec<T>where
T: Sync,
impl<T> Unpin for SyncCodec<T>where
T: Unpin,
impl<T> UnwindSafe for SyncCodec<T>where
T: UnwindSafe,
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