Skip to main content

StreamableDS

Trait StreamableDS 

Source
pub trait StreamableDS {
    type Item: TryInto<Resource, Error = Self::Err>;
    type Err;

    // Required methods
    fn fetch<'life0, 'async_trait>(
        &'life0 self,
    ) -> Pin<Box<dyn Future<Output = Result<BoxStream<'_, Result<Self::Item, Self::Err>>, Self::Err>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn stream<'life0, 'async_trait>(
        &'life0 self,
    ) -> Pin<Box<dyn Future<Output = Result<BoxStream<'_, Result<Resource, Self::Err>>, Self::Err>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn fetch_where<'life0, 'life1, 'async_trait>(
        &'life0 self,
        exp: &'life1 Expression,
    ) -> Pin<Box<dyn Future<Output = Result<BoxStream<'_, Result<Self::Item, Self::Err>>, Self::Err>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;
    fn stream_where<'life0, 'life1, 'async_trait>(
        &'life0 self,
        exp: &'life1 Expression,
    ) -> Pin<Box<dyn Future<Output = Result<BoxStream<'_, Result<Resource, Self::Err>>, Self::Err>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;
}
Expand description

Capability of a DataSource to asynchronously stream Features or Resources.

Required Associated Types§

Source

type Item: TryInto<Resource, Error = Self::Err>

Type representing a Feature which must be convertible to a Resource.

Source

type Err

Error raised by this.

Required Methods§

Source

fn fetch<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<BoxStream<'_, Result<Self::Item, Self::Err>>, Self::Err>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Return an unfiltered stream of all data source Features.

Source

fn stream<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<BoxStream<'_, Result<Resource, Self::Err>>, Self::Err>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Return an unfiltered stream of all data source Resources.

Source

fn fetch_where<'life0, 'life1, 'async_trait>( &'life0 self, exp: &'life1 Expression, ) -> Pin<Box<dyn Future<Output = Result<BoxStream<'_, Result<Self::Item, Self::Err>>, Self::Err>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Return a filtered stream of Features satisfying a CQL2 filter Expression.

Source

fn stream_where<'life0, 'life1, 'async_trait>( &'life0 self, exp: &'life1 Expression, ) -> Pin<Box<dyn Future<Output = Result<BoxStream<'_, Result<Resource, Self::Err>>, Self::Err>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Return a filtered stream of Resources satisfying a CQL2 filter Expression.

Implementors§