Skip to content

[Question] purpose of eventually-util::optional::Aggregate #163

Answered by ar3s3ru
danieleades asked this question in Q&A
Discussion options

You must be logged in to vote

Hey there!

The optional::Aggregate trait is meant to provide a nicer API for Aggregate states that can be optional (which is probably 99.99% of cases btw).

Specifically, the *_first and *_next methods are an alternative of doing pattern matching on the value of State.

You could still use the base Aggregate trait, this is just a zero-cost abstraction :)

Replies: 1 comment 7 replies

Comment options

You must be logged in to vote
7 replies
@danieleades
Comment options

@ar3s3ru
Comment options

@danieleades
Comment options

@ar3s3ru
Comment options

@danieleades
Comment options

Answer selected by danieleades
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #160 on September 03, 2021 18:51.