pub struct WithTaba<R: Runtime>(/* private fields */);Expand description
A [tauri::Builder] answering Taba, wrapped to protect the invoke handler.
This overwrites any previous invoke_handler, so all previous commands reject as not found.
If you want those commands handled, pass them to WithTaba::with_fallback instead.
Making one takes Tauri’s async runtime, so an app that sets its own with
[tauri::async_runtime::set] has to do so first.
Implementations§
Source§impl<R: Runtime> WithTaba<R>
impl<R: Runtime> WithTaba<R>
Sourcepub fn new(builder: Builder<R>, router: Router) -> Self
pub fn new(builder: Builder<R>, router: Router) -> Self
Answers only Taba commands, with router.
Sourcepub fn with_fallback<F>(
builder: Builder<R>,
router: Router,
fallback: F,
) -> Self
pub fn with_fallback<F>( builder: Builder<R>, router: Router, fallback: F, ) -> Self
Answers Taba commands with router, otherwise passing through to fallback.
Trait Implementations§
Auto Trait Implementations§
impl<R> !Freeze for WithTaba<R>
impl<R> !RefUnwindSafe for WithTaba<R>
impl<R> Send for WithTaba<R>
impl<R> !Sync for WithTaba<R>
impl<R> Unpin for WithTaba<R>
impl<R> UnsafeUnpin for WithTaba<R>
impl<R> !UnwindSafe for WithTaba<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