pub struct WireReader { /* private fields */ }Expand description
Reads one independent view of a WireSnapshot.
Implementations§
Source§impl WireReader
impl WireReader
pub fn new(nodes: Vec<SchemaValueNode>) -> WireReader
pub fn take(&mut self, index: i32) -> Result<SchemaValueNode, WireError>
pub fn push(&mut self, node: SchemaValueNode) -> Result<i32, WireError>
Sourcepub fn discard(&mut self, index: i32) -> Result<(), WireError>
pub fn discard(&mut self, index: i32) -> Result<(), WireError>
Consume an unbound field, releasing its resources and checking its edges without constructing a recursive value. The explicit stack also bounds stack usage for deeply nested fields not consumed by a typed decoder.
pub fn finish(self) -> Result<(), WireError>
Auto Trait Implementations§
impl !Send for WireReader
impl !Sync for WireReader
impl Freeze for WireReader
impl RefUnwindSafe for WireReader
impl Unpin for WireReader
impl UnsafeUnpin for WireReader
impl UnwindSafe for WireReader
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