Documentation
¶
Index ¶
- Variables
- func GetLatestEpochKey() []byte
- func GetReleaseAccountKey(epoch uint64, index uint32) []byte
- func GetReleaseAmountKey(epoch uint64, account common.Address) []byte
- func GetReleaseEpochKey(epoch uint64) []byte
- func GetRestrictingKey(account common.Address) []byte
- type ReleaseAmountInfo
- type RestrictingInfo
- type RestrictingPlan
- type Result
Constants ¶
This section is empty.
Variables ¶
View Source
var ( RestrictingKeyPrefix = []byte("RestrictInfo") RestrictRecordKeyPrefix = []byte("RestrictRecord") EpochPrefix = []byte("RestrictEpoch") )
Functions ¶
func GetLatestEpochKey ¶
func GetLatestEpochKey() []byte
func GetReleaseAccountKey ¶
ReleaseAccountKey used for search the index of the restricting account in the released account list at target epoch. key: prefix + epoch + index
func GetReleaseAmountKey ¶
RestrictingKey used for search restricting entry info. key: prefix + epoch + account
func GetReleaseEpochKey ¶
ReleaseNumberKey used for search records at target epoch. key: prefix + epoch
func GetRestrictingKey ¶
RestrictingKey used for search restricting info. key: prefix + account
Types ¶
type ReleaseAmountInfo ¶
type ReleaseAmountInfo struct {
Height uint64 `json:"blockNumber"` // blockNumber representation of the block number at the released epoch
Amount *hexutil.Big `json:"amount"` // amount representation of the released amount
}
for plugin test
type RestrictingInfo ¶
type RestrictingInfo struct {
NeedRelease *big.Int
StakingAmount *big.Int
CachePlanAmount *big.Int
//Balance *big.Int // Balance representation all locked amount
//Debt *big.Int // Debt representation will released amount.
//DebtSymbol bool // Debt is owed to release in the past while symbol is true, else Debt can be used instead of release
ReleaseList []uint64 // ReleaseList representation which epoch will release restricting
}
for genesis and plugin test
func (*RestrictingInfo) RemoveEpoch ¶
func (r *RestrictingInfo) RemoveEpoch(epoch uint64)
type RestrictingPlan ¶
type RestrictingPlan struct {
Epoch uint64 `json:"epoch"` // epoch representation of the released epoch at the target blockNumber
Amount *big.Int `json:"amount"` // amount representation of the released amount
}
for contract, plugin test, byte util
Click to show internal directories.
Click to hide internal directories.