VotingState

scalus.cardano.ledger.VotingState
See theVotingState companion object
case class VotingState(dreps: Map[Credential, DRepState], numDormantEpochs: EpochNo, committeeState: Map[Credential, CommitteeAuthorization])

The voting state, the Haskell VState.

Value parameters

committeeState

the authorization of each committee cold credential that has one, vsCommitteeState of the ledger, spec [DM-1]. It is the third field, not the second as in Haskell, so that the product accessors of the earlier fields keep their types (D29).

numDormantEpochs

the number of epochs in a row with no active proposal, vsNumDormantEpochs of the ledger, spec [DM-3]. A tx with a proposal adds it to the DRep expiries and resets it (eras/conway/impl/src/Cardano/Ledger/Conway/Rules/Certs.hs:313-333), spec [DR-3].

Attributes

Companion
object
Graph
Supertypes
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any
Show all

Members list

Value members

Constructors

def this(dreps: Map[Credential, DRepState] = ...)

The 1.4 constructor, with no dormant counter and no committee state, spec D17. Not deprecated: a call that names only dreps resolves to it, and is correct (D120).

The 1.4 constructor, with no dormant counter and no committee state, spec D17. Not deprecated: a call that names only dreps resolves to it, and is correct (D120).

Attributes

Concrete methods

def copy(dreps: Map[Credential, DRepState] = ..., numDormantEpochs: EpochNo = ..., committeeState: Map[Credential, CommitteeAuthorization] = ...): VotingState

The copy of a case class, written out because the 1.4 copy below suppresses the synthetic one, D120.

The copy of a case class, written out because the 1.4 copy below suppresses the synthetic one, D120.

Attributes

def copy(dreps: Map[Credential, DRepState]): VotingState

The 1.4 copy, binary compatible; it keeps the dormant counter and the committee state, D120.

The 1.4 copy, binary compatible; it keeps the dormant counter and the committee state, D120.

Attributes

Inherited methods

def productElementNames: Iterator[String]

Attributes

Inherited from:
Product
def productIterator: Iterator[Any]

Attributes

Inherited from:
Product