pub trait InvokeExt: Invoke {
// Provided methods
fn invoke_values<P, Params, Results, Paths>(
&self,
cx: Self::Context,
instance: &str,
func: &str,
params: Params,
paths: Paths,
) -> impl Future<Output = Result<(Results, Option<impl Future<Output = Result<()>> + Send + 'static + use<Self, P, Params, Results, Paths>>)>> + Send
where Paths: AsRef<[P]> + Send,
P: AsRef<[Option<usize>]> + Send + Sync,
Params: TupleEncode + Send,
Results: TupleDecode + Send,
<Params::Encoder as Encoder<Params>>::Error: Error + Send + Sync + 'static,
<Results::Decoder as Decoder>::Error: Error + Send + Sync + 'static { ... }
fn invoke_values_blocking<P, Params, Results>(
&self,
cx: Self::Context,
instance: &str,
func: &str,
params: Params,
paths: impl AsRef<[P]> + Send,
) -> impl Future<Output = Result<Results>> + Send
where P: AsRef<[Option<usize>]> + Send + Sync,
Params: TupleEncode + Send,
Results: TupleDecode + Send,
<Params::Encoder as Encoder<Params>>::Error: Error + Send + Sync + 'static,
<Results::Decoder as Decoder>::Error: Error + Send + Sync + 'static { ... }
fn timeout(&self, timeout: Duration) -> Timeout<'_, Self> { ... }
fn timeout_owned(self, timeout: Duration) -> TimeoutOwned<Self>
where Self: Sized { ... }
}Expand description
Extension trait for Invoke
Provided Methods§
Sourcefn invoke_values<P, Params, Results, Paths>(
&self,
cx: Self::Context,
instance: &str,
func: &str,
params: Params,
paths: Paths,
) -> impl Future<Output = Result<(Results, Option<impl Future<Output = Result<()>> + Send + 'static + use<Self, P, Params, Results, Paths>>)>> + Send
fn invoke_values<P, Params, Results, Paths>( &self, cx: Self::Context, instance: &str, func: &str, params: Params, paths: Paths, ) -> impl Future<Output = Result<(Results, Option<impl Future<Output = Result<()>> + Send + 'static + use<Self, P, Params, Results, Paths>>)>> + Send
Invoke function func on instance instance using typed Params and Results
Sourcefn invoke_values_blocking<P, Params, Results>(
&self,
cx: Self::Context,
instance: &str,
func: &str,
params: Params,
paths: impl AsRef<[P]> + Send,
) -> impl Future<Output = Result<Results>> + Send
fn invoke_values_blocking<P, Params, Results>( &self, cx: Self::Context, instance: &str, func: &str, params: Params, paths: impl AsRef<[P]> + Send, ) -> impl Future<Output = Result<Results>> + Send
Invoke function func on instance instance using typed Params and Results
This is like Self::invoke_values, but it only results once all I/O is done
Sourcefn timeout(&self, timeout: Duration) -> Timeout<'_, Self>
fn timeout(&self, timeout: Duration) -> Timeout<'_, Self>
Returns a Timeout, wrapping Self with an implementation of Invoke, which will
error, if call to Invoke::invoke does not return within a supplied timeout
Sourcefn timeout_owned(self, timeout: Duration) -> TimeoutOwned<Self>where
Self: Sized,
fn timeout_owned(self, timeout: Duration) -> TimeoutOwned<Self>where
Self: Sized,
This is like InvokeExt::timeout, but moves Self and returns corresponding TimeoutOwned
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".