pub struct PromiseResult { /* private fields */ }Implementations§
Source§impl PromiseResult
impl PromiseResult
Sourcepub async fn get(&self) -> Vec<u8> ⓘ
pub async fn get(&self) -> Vec<u8> ⓘ
Awaits the promise result. The agent is suspended until the promise is completed; the completed payload is then returned.
On WASI P2 this was a non-blocking get() -> Option<...> paired with a
subscribe() -> pollable; the P3 wasi:io/poll pollable is gone, so the
host get-promise-result.get is now an async func that awaits directly.
Auto Trait Implementations§
impl !Freeze for PromiseResult
impl RefUnwindSafe for PromiseResult
impl Send for PromiseResult
impl Sync for PromiseResult
impl Unpin for PromiseResult
impl UnsafeUnpin for PromiseResult
impl UnwindSafe for PromiseResult
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