pub struct Dispatcher {}Implementations§
Source§impl Dispatcher
impl Dispatcher
pub fn spawn_local(future: impl Future<Output = ()> + 'static) -> TaskHandle<()> ⓘwhere
Self: 'static,
pub fn after_deadline( deadline: MonotonicInstant, ) -> impl Future<Output = ()> + 'static
pub fn client_from_zx_channel<P>( client_end: ClientEnd<P, Channel>, ) -> ClientEnd<P, Transport>
Trait Implementations§
Source§impl Clone for Dispatcher
impl Clone for Dispatcher
Source§fn clone(&self) -> Dispatcher
fn clone(&self) -> Dispatcher
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Default for Dispatcher
impl Default for Dispatcher
Source§fn default() -> Dispatcher
fn default() -> Dispatcher
Returns the “default value” for a type. Read more
Source§impl GetAsyncDispatcher for Dispatcher
impl GetAsyncDispatcher for Dispatcher
Source§fn try_get_async_dispatcher(&self) -> Option<AsyncDispatcher>
fn try_get_async_dispatcher(&self) -> Option<AsyncDispatcher>
Returns a refcounted handle to the active dispatcher for this object, if there is one.
Some types of dispatchers (like for the current dispatcher of a thread) may not always have
an active dispatcher, so it is returned as an option.
§fn get_async_dispatcher(&self) -> AsyncDispatcher
fn get_async_dispatcher(&self) -> AsyncDispatcher
Returns a refcounted handle to the active dispatcher for this object. Read more
Auto Trait Implementations§
impl Freeze for Dispatcher
impl RefUnwindSafe for Dispatcher
impl Send for Dispatcher
impl Sync for Dispatcher
impl Unpin for Dispatcher
impl UnsafeUnpin for Dispatcher
impl UnwindSafe for Dispatcher
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> DispatcherTimerExt for Twhere
T: GetAsyncDispatcher,
impl<T> DispatcherTimerExt for Twhere
T: GetAsyncDispatcher,
Source§fn after_deadline(&self, deadline: Instant<MonotonicTimeline>) -> AfterDeadline
fn after_deadline(&self, deadline: Instant<MonotonicTimeline>) -> AfterDeadline
Returns a future that will fire when after the given deadline time. Read more
Source§fn try_after_deadline(
&self,
deadline: Instant<MonotonicTimeline>,
) -> Option<AfterDeadline>
fn try_after_deadline( &self, deadline: Instant<MonotonicTimeline>, ) -> Option<AfterDeadline>
Returns a future that will fire when after the given deadline time. Read more
Source§impl<T, D> Encode<Ambiguous1, D> for Twhere
D: ResourceDialect,
impl<T, D> Encode<Ambiguous1, D> for Twhere
D: ResourceDialect,
Source§impl<T, D> Encode<Ambiguous2, D> for Twhere
D: ResourceDialect,
impl<T, D> Encode<Ambiguous2, D> for Twhere
D: ResourceDialect,
§impl<F, N> FidlIntoNative<Box<N>> for Fwhere
F: FidlIntoNative<N>,
impl<F, N> FidlIntoNative<Box<N>> for Fwhere
F: FidlIntoNative<N>,
fn fidl_into_native(self) -> Box<N>
§impl<T> InstanceFromServiceTransport<T> for T
impl<T> InstanceFromServiceTransport<T> for T
§fn from_service_transport(handle: T) -> T
fn from_service_transport(handle: T) -> T
Converts the given service transport handle of type
T to [Self]§impl<T> IntoAny for T
impl<T> IntoAny for T
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more§impl<D> OnDispatcher for D
impl<D> OnDispatcher for D
§fn on_dispatcher<R>(
&self,
f: impl FnOnce(Option<AsyncDispatcherRef<'_>>) -> R,
) -> R
fn on_dispatcher<R>( &self, f: impl FnOnce(Option<AsyncDispatcherRef<'_>>) -> R, ) -> R
§fn on_maybe_dispatcher<R, E>(
&self,
f: impl FnOnce(AsyncDispatcherRef<'_>) -> Result<R, E>,
) -> Result<R, E>where
E: From<Status>,
fn on_maybe_dispatcher<R, E>(
&self,
f: impl FnOnce(AsyncDispatcherRef<'_>) -> Result<R, E>,
) -> Result<R, E>where
E: From<Status>,
§fn spawn(
&self,
future: impl Future<Output = ()> + Send + 'static,
) -> JoinHandle<()>where
D: 'static,
fn spawn(
&self,
future: impl Future<Output = ()> + Send + 'static,
) -> JoinHandle<()>where
D: 'static,
Spawn an asynchronous task on this dispatcher. If this returns
Ok then the task has
successfully been scheduled and will run or be cancelled and dropped when the dispatcher
shuts down. The returned future’s result will be Ok if the future completed
successfully, or an Err if the task did not complete for some reason (like the
dispatcher shut down). Read more