pub trait Stream: Send + Sync {
type Cursor: StreamCursor;
// Required methods
fn publish<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
subject: &'life1 str,
id: &'life2 str,
digest: ContentDigest,
headers: Headers,
) -> Pin<Box<dyn Future<Output = BusResult<PublishAck>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait;
fn consumer<'life0, 'life1, 'async_trait>(
&'life0 self,
owner: DurableOwner<'life1>,
) -> Pin<Box<dyn Future<Output = BusResult<Self::Cursor>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
}Required Associated Types§
type Cursor: StreamCursor
Required Methods§
fn publish<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
subject: &'life1 str,
id: &'life2 str,
digest: ContentDigest,
headers: Headers,
) -> Pin<Box<dyn Future<Output = BusResult<PublishAck>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Sourcefn consumer<'life0, 'life1, 'async_trait>(
&'life0 self,
owner: DurableOwner<'life1>,
) -> Pin<Box<dyn Future<Output = BusResult<Self::Cursor>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn consumer<'life0, 'life1, 'async_trait>(
&'life0 self,
owner: DurableOwner<'life1>,
) -> Pin<Box<dyn Future<Output = BusResult<Self::Cursor>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Attaches to the owner’s durable, created separately; this client cannot create workload consumers.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".