Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Account ¶
type Account struct { Address Address `json:"address"` Height Height `json:"height"` GoldTokenBalance Amount `json:"availableGoldBalance"` TotalLockedGoldBalance Amount `json:"totalLockedGoldBalance"` NonVotingLockedGoldBalance Amount `json:"nonVotingLockedGoldBalance"` VotingLockedGoldBalance Amount `json:"votingLockedGoldBalance"` PendingWithdrawalBalance Amount `json:"pendingWithdrawalBalance"` CeloUSDValue Amount `json:"celoUSDValue"` Delegations []*Delegation `json:"delegations"` }
Account is a type that contains all the relevant information that Anthem seeks for an account
type Amount ¶
type Amount = string
Amount is any balance or vote - an abstraction over Celo quantification
type DatedAccount ¶
type DatedAccount struct { SnapshotDate Date `json:"snapshotDate"` Address Address `json:"address"` Height Height `json:"height"` SnapshotReward Amount `json:"snapshotReward"` SnapshotCommission Amount `json:"snapshotCommission"` GoldTokenBalance Amount `json:"availableGoldBalance"` TotalLockedGoldBalance Amount `json:"totalLockedGoldBalance"` NonVotingLockedGoldBalance Amount `json:"nonVotingLockedGoldBalance"` VotingLockedGoldBalance Amount `json:"votingLockedGoldBalance"` PendingWithdrawalBalance Amount `json:"pendingWithdrawalBalance"` CeloUSDValue Amount `json:"celoUSDValue"` Delegations []*Delegation `json:"delegations"` }
DatedAccount represents an account and its details extracted from a daily snapshot
func NewDatedAccount ¶
func NewDatedAccount(date string, address string) *DatedAccount
NewDatedAccount is a constructor for DatedAccount
type Delegation ¶
type Delegation struct { Group Address `json:"group"` TotalVotes Amount `json:"totalVotes"` ActiveVotes Amount `json:"activeVotes" ` PendingVotes Amount `json:"pendingVotes"` }
Delegation represents what Celo calls votes Locked gold from an account bound to a group in the form of votes
type Handler ¶
type Handler = func(w http.ResponseWriter, r *http.Request)
Handler is a small type that helps to make returning closures in the functions below less verbose.
type System ¶
type System struct { Height Height `json:"height"` GoldTokenSupply Amount `json:"goldTokenSupply"` TotalLockedGoldBalance Amount `json:"totalLockedGoldBalance"` NonVotingLockedGoldBalance Amount `json:"nonVotingLockedGoldBalance"` TotalCeloUSDValue Amount `json:"totalCeloUSDValue"` }
System stores the supply details of the blockchain at a particular block height
Click to show internal directories.
Click to hide internal directories.