pub struct Handle { /* private fields */ }Expand description
A running extension.
Implementations§
Source§impl Handle
impl Handle
Sourcepub fn health(&self) -> Option<HealthReport>
pub fn health(&self) -> Option<HealthReport>
The last health report.
Sourcepub async fn wait_for(&self, f: impl Fn(&Status) -> bool) -> Status
pub async fn wait_for(&self, f: impl Fn(&Status) -> bool) -> Status
Waits for a status matching f.
Sourcepub async fn send(&self, kind: impl Into<String>, payload: Vec<u8>)
pub async fn send(&self, kind: impl Into<String>, payload: Vec<u8>)
Sends an app event (dropped if the extension isn’t running).
Sourcepub async fn set_grants(&self, g: Grants)
pub async fn set_grants(&self, g: Grants)
Replaces the grants: checked on the next call, and told to the extension.
Trait Implementations§
Auto Trait Implementations§
impl Forget for Handle
impl Freeze for Handle
impl Move for Handle
impl RefUnwindSafe for Handle
impl Send for Handle
impl Sync for Handle
impl Unpin for Handle
impl UnsafeUnpin for Handle
impl UnwindSafe for Handle
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T in a tonic::Request