pub struct CanvasJsonPersistenceCodec;Implementations§
Source§impl CanvasJsonPersistenceCodec
impl CanvasJsonPersistenceCodec
pub fn encode_record( &self, record: impl Into<CanvasPersistenceRecord>, ) -> Result<Vec<u8>, CanvasPersistenceCodecError>
pub fn decode_record( &self, bytes: &[u8], ) -> Result<CanvasPersistenceRecord, CanvasPersistenceCodecError>
pub fn decode_envelope( &self, bytes: &[u8], ) -> Result<CanvasPersistenceEnvelope, CanvasPersistenceCodecError>
Trait Implementations§
Source§impl CanvasPersistenceCodec for CanvasJsonPersistenceCodec
impl CanvasPersistenceCodec for CanvasJsonPersistenceCodec
type Error = CanvasPersistenceCodecError
fn encode_checkpoint( &self, checkpoint: &CanvasCheckpoint, ) -> Result<Vec<u8>, Self::Error>
fn decode_checkpoint( &self, bytes: &[u8], ) -> Result<CanvasCheckpoint, Self::Error>
fn encode_log_entry( &self, entry: &CanvasLogEntry, ) -> Result<Vec<u8>, Self::Error>
fn decode_log_entry(&self, bytes: &[u8]) -> Result<CanvasLogEntry, Self::Error>
Source§impl Clone for CanvasJsonPersistenceCodec
impl Clone for CanvasJsonPersistenceCodec
Source§fn clone(&self) -> CanvasJsonPersistenceCodec
fn clone(&self) -> CanvasJsonPersistenceCodec
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for CanvasJsonPersistenceCodec
Source§impl Debug for CanvasJsonPersistenceCodec
impl Debug for CanvasJsonPersistenceCodec
Source§impl Default for CanvasJsonPersistenceCodec
impl Default for CanvasJsonPersistenceCodec
Source§fn default() -> CanvasJsonPersistenceCodec
fn default() -> CanvasJsonPersistenceCodec
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for CanvasJsonPersistenceCodec
impl RefUnwindSafe for CanvasJsonPersistenceCodec
impl Send for CanvasJsonPersistenceCodec
impl Sync for CanvasJsonPersistenceCodec
impl Unpin for CanvasJsonPersistenceCodec
impl UnsafeUnpin for CanvasJsonPersistenceCodec
impl UnwindSafe for CanvasJsonPersistenceCodec
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> Pointable for T
impl<T> Pointable for T
impl<T> Read<Exclusive, BecauseExclusive> for Twhere
T: ?Sized,
Source§impl<R, P> ReadPrimitive<R> for P
impl<R, P> ReadPrimitive<R> for P
Source§fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
Read this value from the supplied reader. Same as
ReadEndian::read_from_little_endian().