pub enum Fetch {
Url(Url),
Request(WorkerRequest),
}Expand description
Construct a Fetch call from a URL string or a Request object. Call its send method to execute
the request.
Variants
Url(Url)
Request(WorkerRequest)
Implementations
sourceimpl Fetch
impl Fetch
sourcepub async fn send(&self) -> Result<WorkerResponse>
pub async fn send(&self) -> Result<WorkerResponse>
Execute a Fetch call and receive a Response.
Auto Trait Implementations
impl RefUnwindSafe for Fetch
impl !Send for Fetch
impl !Sync for Fetch
impl Unpin for Fetch
impl UnwindSafe for Fetch
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more