pub struct ZeroCopyParser<'a> { /* private fields */ }
Expand description
Zero-copy JSON parser implementation
Implementations§
Source§impl<'a> ZeroCopyParser<'a>
impl<'a> ZeroCopyParser<'a>
Sourcepub fn with_max_depth(max_depth: usize) -> Self
pub fn with_max_depth(max_depth: usize) -> Self
Create parser with custom max depth
Sourcepub fn parse_value(&mut self) -> DomainResult<LazyJsonValue<'a>>
pub fn parse_value(&mut self) -> DomainResult<LazyJsonValue<'a>>
Parse JSON value starting at current position
Trait Implementations§
Source§impl<'a> Default for ZeroCopyParser<'a>
impl<'a> Default for ZeroCopyParser<'a>
Source§impl<'a> LazyParser<'a> for ZeroCopyParser<'a>
impl<'a> LazyParser<'a> for ZeroCopyParser<'a>
type Output = LazyJsonValue<'a>
type Error = DomainError
Source§fn parse_lazy(&mut self, input: &'a [u8]) -> Result<Self::Output, Self::Error>
fn parse_lazy(&mut self, input: &'a [u8]) -> Result<Self::Output, Self::Error>
Parse input lazily, returning references into the original buffer
Source§fn is_complete(&self) -> bool
fn is_complete(&self) -> bool
Check if parsing is complete
Auto Trait Implementations§
impl<'a> Freeze for ZeroCopyParser<'a>
impl<'a> RefUnwindSafe for ZeroCopyParser<'a>
impl<'a> Send for ZeroCopyParser<'a>
impl<'a> Sync for ZeroCopyParser<'a>
impl<'a> Unpin for ZeroCopyParser<'a>
impl<'a> UnwindSafe for ZeroCopyParser<'a>
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