pub trait Instance<O>: Sized + Sendwhere
O: OperationDeclaration,{
type Error: Error + Send + Sync + 'static;
// Required methods
fn id(&self) -> Id;
fn status(&self) -> impl Future<Output = Result<Status, Self::Error>> + Send;
fn cancel(&self) -> impl Future<Output = Result<(), Self::Error>> + Send;
fn join(
self,
) -> impl Future<Output = Result<Response<<O as OperationDeclaration>::Response>, Self::Error>> + Send;
fn detach(self) -> Id;
// Provided method
fn cancel_and_join(
self,
) -> impl Future<Output = Result<Response<<O as OperationDeclaration>::Response>, Self::Error>> + Send { ... }
}Required Associated Types§
Required Methods§
fn id(&self) -> Id
fn status(&self) -> impl Future<Output = Result<Status, Self::Error>> + Send
fn cancel(&self) -> impl Future<Output = Result<(), Self::Error>> + Send
fn join( self, ) -> impl Future<Output = Result<Response<<O as OperationDeclaration>::Response>, Self::Error>> + Send
fn detach(self) -> Id
Provided Methods§
fn cancel_and_join( self, ) -> impl Future<Output = Result<Response<<O as OperationDeclaration>::Response>, Self::Error>> + Send
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".