pub struct Noop;Expand description
A backend whose client answers every request with an empty 200 OK.
Useful for tests and examples that exercise the crawler without network access.
Trait Implementations§
Source§impl Backend for Noop
impl Backend for Noop
Source§fn connect(&self) -> impl Future<Output = Result<Self::Session>> + Send
fn connect(&self) -> impl Future<Output = Result<Self::Session>> + Send
Returns a session for the next request, sent directly, from the
crawler itself, with the backend’s own cookies and sessions. Read more
Source§fn connect_as(
&self,
identity: &Identity,
) -> impl Future<Output = Result<Self::Session>> + Send
fn connect_as( &self, identity: &Identity, ) -> impl Future<Output = Result<Self::Session>> + Send
Returns a session for the next request, which goes out as
identity,
for a crawl with identities. Read moreimpl Copy for Noop
Auto Trait Implementations§
impl Freeze for Noop
impl RefUnwindSafe for Noop
impl Send for Noop
impl Sync for Noop
impl Unpin for Noop
impl UnsafeUnpin for Noop
impl UnwindSafe for Noop
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