Skip to main content

GetStream

Trait GetStream 

Source
pub trait GetStream: Send + Sync {
    // Required methods
    fn get_stream<'a>(
        &'a self,
        identity: &'a StreamIdentity,
    ) -> impl Future<Output = Result<Option<Entity>, RepositoryError>> + Send + 'a;
    fn get_streams<'a>(
        &'a self,
        identities: &'a [StreamIdentity],
    ) -> impl Future<Output = Result<Vec<Entity>, RepositoryError>> + Send + 'a;
}
Expand description

Async stream-aware aggregate loading.

Required Methods§

Source

fn get_stream<'a>( &'a self, identity: &'a StreamIdentity, ) -> impl Future<Output = Result<Option<Entity>, RepositoryError>> + Send + 'a

Source

fn get_streams<'a>( &'a self, identities: &'a [StreamIdentity], ) -> impl Future<Output = Result<Vec<Entity>, RepositoryError>> + Send + 'a

Dyn Compatibility§

This trait is not dyn compatible.

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

Implementors§