Enum netsblox_vm::runtime::MaybeAsync
source · pub enum MaybeAsync<T, K> {
Sync(T),
Async(K),
}Expand description
The result of an operation that might be synchronous or asynchronous.
Variants§
Sync(T)
A synchronous result with a return value of type T.
Async(K)
An asynchronous result with the given async key type K,
which is expected to be usable to later obtain an AsyncResult<T>.
Auto Trait Implementations§
impl<T, K> RefUnwindSafe for MaybeAsync<T, K>where K: RefUnwindSafe, T: RefUnwindSafe,
impl<T, K> Send for MaybeAsync<T, K>where K: Send, T: Send,
impl<T, K> Sync for MaybeAsync<T, K>where K: Sync, T: Sync,
impl<T, K> Unpin for MaybeAsync<T, K>where K: Unpin, T: Unpin,
impl<T, K> UnwindSafe for MaybeAsync<T, K>where K: UnwindSafe, T: UnwindSafe,
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