Struct tauri::InvokeResolver
source · pub struct InvokeResolver<R: Runtime = Wry> { /* private fields */ }
Expand description
Resolver of a invoke message.
Implementations§
source§impl<R: Runtime> InvokeResolver<R>
impl<R: Runtime> InvokeResolver<R>
sourcepub fn respond_async<T, F>(self, task: F)
pub fn respond_async<T, F>(self, task: F)
Reply to the invoke promise with an async task.
sourcepub fn respond_async_serialized<F>(self, task: F)
pub fn respond_async_serialized<F>(self, task: F)
Reply to the invoke promise with an async task which is already serialized.
sourcepub fn respond<T: Serialize>(self, value: Result<T, InvokeError>)
pub fn respond<T: Serialize>(self, value: Result<T, InvokeError>)
Reply to the invoke promise with a serializable value.
sourcepub fn invoke_error(self, error: InvokeError)
pub fn invoke_error(self, error: InvokeError)
Reject the invoke promise with an InvokeError
.
Trait Implementations§
Auto Trait Implementations§
impl<R = Wry<EventLoopMessage>> !RefUnwindSafe for InvokeResolver<R>
impl<R> Send for InvokeResolver<R>
impl<R> Sync for InvokeResolver<R>
impl<R> Unpin for InvokeResolver<R>where
<R as Runtime<EventLoopMessage>>::Dispatcher: Unpin,
<R as Runtime<EventLoopMessage>>::GlobalShortcutManager: Unpin,
<R as Runtime<EventLoopMessage>>::Handle: Unpin,
impl<R = Wry<EventLoopMessage>> !UnwindSafe for InvokeResolver<R>
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