Skip to main content

Invocations

Trait Invocations 

Source
pub trait Invocations:
    Send
    + Sync
    + 'static {
    type WatchStream: Stream<Item = Result<InvocationsWatchResponse, Status>> + Send + 'static;

    // Required methods
    fn get<'life0, 'async_trait>(
        &'life0 self,
        request: Request<InvocationsGetRequest>,
    ) -> Pin<Box<dyn Future<Output = Result<Response<InvocationsGetResponse>, Status>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn cancel<'life0, 'async_trait>(
        &'life0 self,
        request: Request<InvocationsCancelRequest>,
    ) -> Pin<Box<dyn Future<Output = Result<Response<InvocationsCancelResponse>, Status>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn watch<'life0, 'async_trait>(
        &'life0 self,
        request: Request<InvocationsWatchRequest>,
    ) -> Pin<Box<dyn Future<Output = Result<Response<Self::WatchStream>, Status>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
}
Expand description

Generated trait containing gRPC methods that should be implemented for use with InvocationsServer.

Required Associated Types§

Source

type WatchStream: Stream<Item = Result<InvocationsWatchResponse, Status>> + Send + 'static

Server streaming response type for the Watch method.

Required Methods§

Source

fn get<'life0, 'async_trait>( &'life0 self, request: Request<InvocationsGetRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<InvocationsGetResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Inspect an invocation owned by the caller; unknown or foreign instance handles refuse.

Source

fn cancel<'life0, 'async_trait>( &'life0 self, request: Request<InvocationsCancelRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<InvocationsCancelResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Request cooperative cancellation of a caller-owned invocation and report its state; cancellation need not discard a handler’s typed final result.

Source

fn watch<'life0, 'async_trait>( &'life0 self, request: Request<InvocationsWatchRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<Self::WatchStream>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Observe state changes of a caller-owned invocation through settlement; foreign or unknown handles refuse.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§