Struct rustdds::CDRSerializerAdapter
source · [−]pub struct CDRSerializerAdapter<D, BO = LittleEndian>where
BO: ByteOrder,{ /* private fields */ }
Expand description
This type adapts CdrSerializer
(which implements
serde::Serializer
) to work as a no_key::SerializerAdapter
and
with_key::SerializerAdapter
.
CdrSerializer
cannot directly implement the trait itself, because
CdrSerializer
has the type parameter BO open, and the adapter needs to
be bi-endian.
Trait Implementations
sourceimpl<D, BO> SerializerAdapter<D> for CDRSerializerAdapter<D, BO>where
D: Serialize,
BO: ByteOrder,
impl<D, BO> SerializerAdapter<D> for CDRSerializerAdapter<D, BO>where
D: Serialize,
BO: ByteOrder,
fn output_encoding() -> RepresentationIdentifier
fn to_bytes(value: &D) -> Result<Bytes, Error>
sourceimpl<D, BO> SerializerAdapter<D> for CDRSerializerAdapter<D, BO>where
D: Keyed + Serialize,
<D as Keyed>::K: Serialize,
BO: ByteOrder,
impl<D, BO> SerializerAdapter<D> for CDRSerializerAdapter<D, BO>where
D: Keyed + Serialize,
<D as Keyed>::K: Serialize,
BO: ByteOrder,
fn key_to_bytes(value: &D::K) -> Result<Bytes, Error>
Auto Trait Implementations
impl<D, BO> RefUnwindSafe for CDRSerializerAdapter<D, BO>where
BO: RefUnwindSafe,
D: RefUnwindSafe,
impl<D, BO> Send for CDRSerializerAdapter<D, BO>where
BO: Send,
D: Send,
impl<D, BO> Sync for CDRSerializerAdapter<D, BO>where
BO: Sync,
D: Sync,
impl<D, BO> Unpin for CDRSerializerAdapter<D, BO>where
BO: Unpin,
D: Unpin,
impl<D, BO> UnwindSafe for CDRSerializerAdapter<D, BO>where
BO: UnwindSafe,
D: UnwindSafe,
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more