pub struct Walk<T: Transport> { /* private fields */ }Expand description
Async stream for walking an OID subtree using GETNEXT.
Created by Client::walk_getnext().
Implementations§
Source§impl<T> Walk<T>where
T: Transport + 'static,
impl<T> Walk<T>where
T: Transport + 'static,
Sourcepub async fn next(&mut self) -> Option<Result<VarBind>>
pub async fn next(&mut self) -> Option<Result<VarBind>>
Get the next varbind, or None when complete.
Sourcepub async fn collect(self) -> Result<Vec<VarBind>>
pub async fn collect(self) -> Result<Vec<VarBind>>
Collect all remaining varbinds.
If the walk completes with no results, a fallback GET is attempted
on the base OID to handle scalar objects (e.g. sysDescr.0) that a
GETNEXT/GETBULK walk would step past. The result is only returned
when it is a real value and the max_results cap permits it;
genuine absence is swallowed and real errors are propagated.
Trait Implementations§
Source§impl<T: Transport + 'static> Stream for Walk<T>
impl<T: Transport + 'static> Stream for Walk<T>
Auto Trait Implementations§
impl<T> !RefUnwindSafe for Walk<T>
impl<T> !Sync for Walk<T>
impl<T> !UnwindSafe for Walk<T>
impl<T> Freeze for Walk<T>
impl<T> Send for Walk<T>
impl<T> Unpin for Walk<T>
impl<T> UnsafeUnpin for Walk<T>
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
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 more