Documentation ¶
Index ¶
Constants ¶
View Source
const ModuleName = "rewards"
ModuleName is the rewards module name.
Variables ¶
View Source
var RewardPoolAddress = types.NewAddressForModule(ModuleName, []byte("reward-pool"))
RewardPoolAddress is the address of the reward pool.
Functions ¶
This section is empty.
Types ¶
type Parameters ¶
type Parameters struct { Schedule RewardSchedule `json:"schedule"` ParticipationThresholdNumerator uint64 `json:"participation_threshold_numerator"` ParticipationThresholdDenominator uint64 `json:"participation_threshold_denominator"` }
Parameters are the parameters for the rewards module.
type RewardSchedule ¶
type RewardSchedule struct {
Steps []RewardStep `json:"steps"`
}
RewardSchedule is a reward schedule.
type RewardStep ¶
type RewardStep struct { Until beacon.EpochTime `json:"until"` Amount types.BaseUnits `json:"amount"` }
RewardStep is one of the time periods in the reward schedule.
type V1 ¶
type V1 interface { // Parameters queries the rewards module parameters. Parameters(ctx context.Context, round uint64) (*Parameters, error) }
V1 is the v1 rewards module interface.
func NewV1 ¶
func NewV1(rc client.RuntimeClient) V1
NewV1 generates a V1 client helper for the rewards module.
Click to show internal directories.
Click to hide internal directories.