proposal_vote_status.gno
Types
ProposalVoteStatus
ProposalVoteStatus tracks the voting tallies and requirements for a proposal. This structure manages vote counting, quorum calculation, and voting outcome determination.
Methods
Clone
Clone returns an independent copy of the vote status, or nil when the receiver is nil.
Return Values
*ProposalVoteStatus
*ProposalVoteStatus
copied vote tallies and requirements, or nil for a nil receiver.
MaxVotingWeight
Getter methods MaxVotingWeight returns the maximum voting weight captured for the proposal.
Return Values
int64
int64
maximum voting weight used when evaluating the proposal's quorum.
NoWeight
NoWeight returns the total weight of "no" votes.
Return Values
int64
int64
total "no" vote weight
QuorumAmount
QuorumAmount returns the voting weight required for the proposal to satisfy quorum.
Return Values
int64
int64
minimum total vote weight required by this proposal.
SetMaxVotingWeight
SetMaxVotingWeight records the proposal's maximum voting-weight snapshot.
Parameters
maxVotingWeight
int64
maximum voting weight available when the proposal was created.
SetNoWeight
SetNoWeight replaces the proposal's accumulated no-vote weight.
Parameters
no
int64
total weight to record for negative votes.
SetQuorumAmount
SetQuorumAmount records the proposal's quorum requirement.
Parameters
quorumAmount
int64
minimum total vote weight required for this proposal.
SetYesWeight
Setter methods SetYesWeight replaces the proposal's accumulated yes-vote weight.
Parameters
yes
int64
total weight to record for affirmative votes.
YesWeight
YesWeight returns the total weight of "yes" votes.
Return Values
int64
int64
total "yes" vote weight
Constructors
func NewProposalVoteStatus(maxVotingWeight int64, quorumAmount int64) *ProposalVoteStatus(source)
Last updated