VoteAccumulator

org.sigilaris.node.jvm.runtime.consensus.hotstuff.VoteAccumulator
See theVoteAccumulator companion object
final case class VoteAccumulator(votesById: Map[VoteId, Vote], votesByEquivocationKey: Map[EquivocationKey, Vote])

Accumulates votes and detects equivocations (double-voting).

Attributes

Companion
object
Source
Validation.scala
Graph
Supertypes
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any
Show all

Members list

Value members

Concrete methods

def prune(retain: Vote => Boolean): VoteAccumulator

Prunes retained votes with the supplied predicate.

Prunes retained votes with the supplied predicate.

Attributes

Source
Validation.scala
def pruneToVoteIds(retainedVoteIds: Set[VoteId]): VoteAccumulator

Prunes retained votes to the supplied vote-id set.

Prunes retained votes to the supplied vote-id set.

Attributes

Source
Validation.scala

Records a vote, detecting duplicates and equivocations.

Records a vote, detecting duplicates and equivocations.

Attributes

Source
Validation.scala

Number of equivocation keys retained by this accumulator.

Number of equivocation keys retained by this accumulator.

Attributes

Source
Validation.scala

Number of vote bodies retained by this accumulator.

Number of vote bodies retained by this accumulator.

Attributes

Source
Validation.scala
def votesFor(window: HotStuffWindow, proposalId: ProposalId): Vector[Vote]

Returns all votes for the given window and proposal ID.

Returns all votes for the given window and proposal ID.

Attributes

Source
Validation.scala

Inherited methods

def productElementNames: Iterator[String]

Attributes

Inherited from:
Product
def productIterator: Iterator[Any]

Attributes

Inherited from:
Product