[][src]Struct eventually_redis::EventStoreBuilder

pub struct EventStoreBuilder { /* fields omitted */ }

Builder type for EventStore and EventSubscriber types.

The same builder instance can be used to build multiple instances of EventStore and EventSubscriber.

Implementations

impl EventStoreBuilder[src]

pub fn new(client: Client) -> Self[src]

Creates a new builder instance using the specified Redis client.

pub fn stream_page_size(self, size: usize) -> Self[src]

Changes the page size used by the Stream returned in EventStore::stream and EventStore::stream_all.

pub async fn build_store<Id, Event, '_>(
    &'_ self,
    stream_name: &'static str
) -> RedisResult<EventStore<Id, Event>>
[src]

Builds a new EventStore instance.

This method returns an std::future::Future completing after a connection with Redis is successfully established.

pub fn build_subscriber<Id, Event>(
    &self,
    stream_name: &'static str
) -> EventSubscriber<Id, Event>
[src]

Builds a new EventSubscriber instance.

Trait Implementations

impl Clone for EventStoreBuilder[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.