Skip to content

Instantly share code, notes, and snippets.

@samueleresca
Last active December 9, 2021 12:18
Show Gist options
  • Save samueleresca/01c87c37464546766c718e786b322e93 to your computer and use it in GitHub Desktop.
Save samueleresca/01c87c37464546766c718e786b322e93 to your computer and use it in GitHub Desktop.
// ExprOperator that wraps the Add and Multiply methods needed to build a quorum from a set of Node.
type ExprOperator interface {
// Add method aggregate a Node to an Expr with a logical Or (a ∨ b)
// returns the resulting Or operation.
Add(expr Expr) Or
// Multiply method aggregate a Node to an Expr with a logical And (a ∧ b)
// returns the resulting And operation.
Multiply(expr Expr) And
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment