[][src]Struct eventific::Eventific

pub struct Eventific<S, D: 'static + Send + Sync + Debug, St: Store<D> = MemoryStore<D>> { /* fields omitted */ }

Methods

impl<S, D: 'static + Send + Sync + Debug, St: Store<D>> Eventific<S, D, St>[src]

pub fn get_logger(&self) -> &Logger[src]

pub fn spawn<F: Future<Item = (), Error = ()> + Send + 'static>(
    &self,
    future: F
)
[src]

impl<S, D: 'static + Send + Sync + Debug + Clone, St: Store<D>> Eventific<S, D, St>[src]

impl<S: Default, D: 'static + Send + Sync + Debug + Clone + AsRef<str>, St: Store<D>> Eventific<S, D, St>[src]

pub fn create_aggregate(
    &self,
    aggregate_id: Uuid,
    event_data: Vec<D>,
    metadata: Option<HashMap<String, String>>
) -> impl Future<Item = (), Error = EventificError<D>>
[src]

pub fn aggregate(
    &self,
    aggregate_id: Uuid
) -> impl Future<Item = Aggregate<S>, Error = EventificError<D>>
[src]

pub fn add_events_to_aggregate<F: Fn(Aggregate<S>) -> IF, IF: IntoFuture<Item = Vec<D>, Error = Error, Future = FF>, FF: Future<Item = Vec<D>, Error = Error>>(
    &self,
    aggregate_id: Uuid,
    _metadata: Option<HashMap<String, String>>,
    callback: F
) -> impl Future<Item = (), Error = EventificError<D>>
[src]

pub fn total_events(&self) -> impl Future<Item = u64, Error = EventificError<D>>[src]

pub fn total_events_for_aggregate(
    &self,
    aggregate_id: Uuid
) -> impl Future<Item = u64, Error = EventificError<D>>
[src]

pub fn total_aggregates(
    &self
) -> impl Future<Item = u64, Error = EventificError<D>>
[src]

pub fn all_aggregates(
    &self
) -> impl Stream<Item = Aggregate<S>, Error = EventificError<D>>
[src]

pub fn updated_aggregates(
    &self
) -> impl Stream<Item = Aggregate<S>, Error = EventificError<D>>
[src]

impl<S: 'static + Default + Send, D: 'static + Send + Sync + Debug + Clone + AsRef<str>, St: Store<D> + Sync> Eventific<S, D, St>[src]

pub fn grpc_create_aggregate<Input: 'static + Send, Resp: 'static + Send, IC: 'static + FnOnce(&Input) -> &str, VC: 'static + FnOnce(&Input) -> Result<Vec<D>, Error> + Send, RC: 'static + FnOnce() -> Resp + Send>(
    &self,
    ctx: RequestOptions,
    input: Input,
    id_callback: IC,
    event_callback: VC,
    result_callback: RC
) -> SingleResponse<Resp>
[src]

pub fn grpc_add_events_to_aggregate<Input: 'static + Sync + Send + Clone, Resp: 'static + Send, IC: 'static + FnOnce(&Input) -> &str, VC: 'static + Fn(&Input, Aggregate<S>) -> IF + Send, RC: 'static + FnOnce() -> Resp + Send, IF: 'static + IntoFuture<Item = Vec<D>, Error = Error, Future = FF>, FF: 'static + Future<Item = Vec<D>, Error = Error> + Send>(
    &self,
    ctx: RequestOptions,
    input: Input,
    id_callback: IC,
    event_callback: VC,
    result_callback: RC
) -> SingleResponse<Resp>
[src]

Trait Implementations

impl<S, D: 'static + Send + Sync + Debug, St: Store<D>> Clone for Eventific<S, D, St>[src]

fn clone_from(&mut self, source: &Self)1.0.0[src]

Performs copy-assignment from source. Read more

Auto Trait Implementations

impl<S, D, St> Send for Eventific<S, D, St>

impl<S, D, St> Unpin for Eventific<S, D, St> where
    D: Unpin,
    St: Unpin

impl<S, D, St> Sync for Eventific<S, D, St> where
    St: Sync

impl<S, D, St = MemoryStore<D>> !UnwindSafe for Eventific<S, D, St>

impl<S, D, St = MemoryStore<D>> !RefUnwindSafe for Eventific<S, D, St>

Blanket Implementations

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.

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

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

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

impl<T> Erased for T