Struct ockam_multiaddr::codec::StdCodec
source · [−]pub struct StdCodec;
Trait Implementations
sourceimpl Codec for StdCodec
impl Codec for StdCodec
sourcefn split_str<'a>(
&self,
_prefix: &str,
input: &'a str
) -> Result<(Checked<&'a str>, &'a str), Error>
fn split_str<'a>(
&self,
_prefix: &str,
input: &'a str
) -> Result<(Checked<&'a str>, &'a str), Error>
Split input string into the value and the remainder.
sourcefn split_bytes<'a>(
&self,
code: Code,
input: &'a [u8]
) -> Result<(Checked<&'a [u8]>, &'a [u8]), Error>
fn split_bytes<'a>(
&self,
code: Code,
input: &'a [u8]
) -> Result<(Checked<&'a [u8]>, &'a [u8]), Error>
Split input bytes into the value and the remainder.
sourcefn is_valid_bytes(&self, code: Code, input: Checked<&[u8]>) -> bool
fn is_valid_bytes(&self, code: Code, input: Checked<&[u8]>) -> bool
Are the given input bytes valid w.r.t. the code?
sourcefn write_bytes(
&self,
val: &ProtoValue<'_>,
buf: &mut dyn Buffer
) -> Result<(), Error>
fn write_bytes(
&self,
val: &ProtoValue<'_>,
buf: &mut dyn Buffer
) -> Result<(), Error>
Write a protocol value to the given buffer.
Auto Trait Implementations
impl RefUnwindSafe for StdCodec
impl Send for StdCodec
impl Sync for StdCodec
impl Unpin for StdCodec
impl UnwindSafe for StdCodec
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
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