Enum scroll::ctx::StrCtx [−][src]
The parsing context for converting a byte sequence to a &str
StrCtx
specifies what byte delimiter to use, and defaults to C-style null terminators. Be careful.
Variants
Delimiter(u8)
DelimiterUntil(u8, usize)
Length(usize)
Methods
impl StrCtx
[src]
impl StrCtx
Trait Implementations
impl Debug for StrCtx
[src]
impl Debug for StrCtx
fn fmt(&self, f: &mut Formatter) -> Result
[src]
fn fmt(&self, f: &mut Formatter) -> Result
Formats the value using the given formatter. Read more
impl Copy for StrCtx
[src]
impl Copy for StrCtx
impl Clone for StrCtx
[src]
impl Clone for StrCtx
fn clone(&self) -> StrCtx
[src]
fn clone(&self) -> StrCtx
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
fn clone_from(&mut self, source: &Self)
1.0.0
[src]Performs copy-assignment from source
. Read more
impl Default for StrCtx
[src]
impl Default for StrCtx
impl<'a> TryFromCtx<'a, StrCtx> for &'a str
[src]
impl<'a> TryFromCtx<'a, StrCtx> for &'a str
type Error = Error
type Size = usize
fn try_from_ctx(
src: &'a [u8],
ctx: StrCtx
) -> Result<(Self, Self::Size), Self::Error>
[src]
fn try_from_ctx(
src: &'a [u8],
ctx: StrCtx
) -> Result<(Self, Self::Size), Self::Error>
Read a &str
from src
using delimiter
impl<'a, T> TryFromCtx<'a, StrCtx, T> for &'a str where
T: AsRef<[u8]>,
[src]
impl<'a, T> TryFromCtx<'a, StrCtx, T> for &'a str where
T: AsRef<[u8]>,