stakingpb

package
v2.5.0-rc2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 4, 2026 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var File_staking_proto protoreflect.FileDescriptor

Functions

This section is empty.

Types

type Bucket

type Bucket struct {
	Index                     uint64                 `protobuf:"varint,1,opt,name=index,proto3" json:"index,omitempty"`
	CandidateAddress          string                 `protobuf:"bytes,2,opt,name=candidateAddress,proto3" json:"candidateAddress,omitempty"`
	StakedAmount              string                 `protobuf:"bytes,3,opt,name=stakedAmount,proto3" json:"stakedAmount,omitempty"`
	StakedDuration            uint32                 `protobuf:"varint,4,opt,name=stakedDuration,proto3" json:"stakedDuration,omitempty"`
	CreateTime                *timestamppb.Timestamp `protobuf:"bytes,5,opt,name=createTime,proto3" json:"createTime,omitempty"`
	StakeStartTime            *timestamppb.Timestamp `protobuf:"bytes,6,opt,name=stakeStartTime,proto3" json:"stakeStartTime,omitempty"`
	UnstakeStartTime          *timestamppb.Timestamp `protobuf:"bytes,7,opt,name=unstakeStartTime,proto3" json:"unstakeStartTime,omitempty"`
	AutoStake                 bool                   `protobuf:"varint,8,opt,name=autoStake,proto3" json:"autoStake,omitempty"`
	Owner                     string                 `protobuf:"bytes,9,opt,name=owner,proto3" json:"owner,omitempty"`
	ContractAddress           string                 `protobuf:"bytes,10,opt,name=contractAddress,proto3" json:"contractAddress,omitempty"`
	StakedDurationBlockNumber uint64                 `protobuf:"varint,11,opt,name=stakedDurationBlockNumber,proto3" json:"stakedDurationBlockNumber,omitempty"`
	CreateBlockHeight         uint64                 `protobuf:"varint,12,opt,name=createBlockHeight,proto3" json:"createBlockHeight,omitempty"`
	StakeStartBlockHeight     uint64                 `protobuf:"varint,13,opt,name=stakeStartBlockHeight,proto3" json:"stakeStartBlockHeight,omitempty"`
	UnstakeStartBlockHeight   uint64                 `protobuf:"varint,14,opt,name=unstakeStartBlockHeight,proto3" json:"unstakeStartBlockHeight,omitempty"`
	// contains filtered or unexported fields
}

func (*Bucket) Descriptor deprecated

func (*Bucket) Descriptor() ([]byte, []int)

Deprecated: Use Bucket.ProtoReflect.Descriptor instead.

func (*Bucket) GetAutoStake

func (x *Bucket) GetAutoStake() bool

func (*Bucket) GetCandidateAddress

func (x *Bucket) GetCandidateAddress() string

func (*Bucket) GetContractAddress

func (x *Bucket) GetContractAddress() string

func (*Bucket) GetCreateBlockHeight

func (x *Bucket) GetCreateBlockHeight() uint64

func (*Bucket) GetCreateTime

func (x *Bucket) GetCreateTime() *timestamppb.Timestamp

func (*Bucket) GetIndex

func (x *Bucket) GetIndex() uint64

func (*Bucket) GetOwner

func (x *Bucket) GetOwner() string

func (*Bucket) GetStakeStartBlockHeight

func (x *Bucket) GetStakeStartBlockHeight() uint64

func (*Bucket) GetStakeStartTime

func (x *Bucket) GetStakeStartTime() *timestamppb.Timestamp

func (*Bucket) GetStakedAmount

func (x *Bucket) GetStakedAmount() string

func (*Bucket) GetStakedDuration

func (x *Bucket) GetStakedDuration() uint32

func (*Bucket) GetStakedDurationBlockNumber

func (x *Bucket) GetStakedDurationBlockNumber() uint64

func (*Bucket) GetUnstakeStartBlockHeight

func (x *Bucket) GetUnstakeStartBlockHeight() uint64

func (*Bucket) GetUnstakeStartTime

func (x *Bucket) GetUnstakeStartTime() *timestamppb.Timestamp

func (*Bucket) ProtoMessage

func (*Bucket) ProtoMessage()

func (*Bucket) ProtoReflect

func (x *Bucket) ProtoReflect() protoreflect.Message

func (*Bucket) Reset

func (x *Bucket) Reset()

func (*Bucket) String

func (x *Bucket) String() string

type BucketIndices

type BucketIndices struct {
	Indices []uint64 `protobuf:"varint,1,rep,packed,name=indices,proto3" json:"indices,omitempty"`
	// contains filtered or unexported fields
}

func (*BucketIndices) Descriptor deprecated

func (*BucketIndices) Descriptor() ([]byte, []int)

Deprecated: Use BucketIndices.ProtoReflect.Descriptor instead.

func (*BucketIndices) GetIndices

func (x *BucketIndices) GetIndices() []uint64

func (*BucketIndices) ProtoMessage

func (*BucketIndices) ProtoMessage()

func (*BucketIndices) ProtoReflect

func (x *BucketIndices) ProtoReflect() protoreflect.Message

func (*BucketIndices) Reset

func (x *BucketIndices) Reset()

func (*BucketIndices) String

func (x *BucketIndices) String() string

type BucketType

type BucketType struct {
	Amount      string `protobuf:"bytes,1,opt,name=amount,proto3" json:"amount,omitempty"`
	Duration    uint64 `protobuf:"varint,2,opt,name=duration,proto3" json:"duration,omitempty"`
	ActivatedAt uint64 `protobuf:"varint,3,opt,name=activatedAt,proto3" json:"activatedAt,omitempty"`
	// contains filtered or unexported fields
}

func (*BucketType) Descriptor deprecated

func (*BucketType) Descriptor() ([]byte, []int)

Deprecated: Use BucketType.ProtoReflect.Descriptor instead.

func (*BucketType) GetActivatedAt

func (x *BucketType) GetActivatedAt() uint64

func (*BucketType) GetAmount

func (x *BucketType) GetAmount() string

func (*BucketType) GetDuration

func (x *BucketType) GetDuration() uint64

func (*BucketType) ProtoMessage

func (*BucketType) ProtoMessage()

func (*BucketType) ProtoReflect

func (x *BucketType) ProtoReflect() protoreflect.Message

func (*BucketType) Reset

func (x *BucketType) Reset()

func (*BucketType) String

func (x *BucketType) String() string

type Candidate

type Candidate struct {
	OwnerAddress       string `protobuf:"bytes,1,opt,name=ownerAddress,proto3" json:"ownerAddress,omitempty"`
	OperatorAddress    string `protobuf:"bytes,2,opt,name=operatorAddress,proto3" json:"operatorAddress,omitempty"`
	RewardAddress      string `protobuf:"bytes,3,opt,name=rewardAddress,proto3" json:"rewardAddress,omitempty"`
	Name               string `protobuf:"bytes,4,opt,name=name,proto3" json:"name,omitempty"`
	Votes              string `protobuf:"bytes,5,opt,name=votes,proto3" json:"votes,omitempty"`
	SelfStakeBucketIdx uint64 `protobuf:"varint,6,opt,name=selfStakeBucketIdx,proto3" json:"selfStakeBucketIdx,omitempty"`
	SelfStake          string `protobuf:"bytes,7,opt,name=selfStake,proto3" json:"selfStake,omitempty"`
	IdentifierAddress  string `protobuf:"bytes,8,opt,name=identifierAddress,proto3" json:"identifierAddress,omitempty"` //if the field is empty, set it to the old owner address
	Pubkey             []byte `protobuf:"bytes,9,opt,name=pubkey,proto3" json:"pubkey,omitempty"`                       // BLS public key
	DeactivatedAt      uint64 `protobuf:"varint,10,opt,name=deactivatedAt,proto3" json:"deactivatedAt,omitempty"`
	// Enables protocol-native voter reward distribution. Existing Hermes
	// candidates are migrated at activation; later opt-in is owner-controlled.
	// This transition is one-way.
	VoterRewardOnchainOptIn bool `protobuf:"varint,11,opt,name=voterRewardOnchainOptIn,proto3" json:"voterRewardOnchainOptIn,omitempty"`
	// True when rewardAddress was explicitly set by a candidate action after
	// IIP-59 activation.
	RewardAddressUpdated bool `protobuf:"varint,12,opt,name=rewardAddressUpdated,proto3" json:"rewardAddressUpdated,omitempty"`
	// contains filtered or unexported fields
}

func (*Candidate) Descriptor deprecated

func (*Candidate) Descriptor() ([]byte, []int)

Deprecated: Use Candidate.ProtoReflect.Descriptor instead.

func (*Candidate) GetDeactivatedAt added in v2.4.0

func (x *Candidate) GetDeactivatedAt() uint64

func (*Candidate) GetIdentifierAddress

func (x *Candidate) GetIdentifierAddress() string

func (*Candidate) GetName

func (x *Candidate) GetName() string

func (*Candidate) GetOperatorAddress

func (x *Candidate) GetOperatorAddress() string

func (*Candidate) GetOwnerAddress

func (x *Candidate) GetOwnerAddress() string

func (*Candidate) GetPubkey added in v2.3.0

func (x *Candidate) GetPubkey() []byte

func (*Candidate) GetRewardAddress

func (x *Candidate) GetRewardAddress() string

func (*Candidate) GetRewardAddressUpdated

func (x *Candidate) GetRewardAddressUpdated() bool

func (*Candidate) GetSelfStake

func (x *Candidate) GetSelfStake() string

func (*Candidate) GetSelfStakeBucketIdx

func (x *Candidate) GetSelfStakeBucketIdx() uint64

func (*Candidate) GetVoterRewardOnchainOptIn

func (x *Candidate) GetVoterRewardOnchainOptIn() bool

func (*Candidate) GetVotes

func (x *Candidate) GetVotes() string

func (*Candidate) ProtoMessage

func (*Candidate) ProtoMessage()

func (*Candidate) ProtoReflect

func (x *Candidate) ProtoReflect() protoreflect.Message

func (*Candidate) Reset

func (x *Candidate) Reset()

func (*Candidate) String

func (x *Candidate) String() string

type CandidateRewardSnapshot

type CandidateRewardSnapshot struct {

	// Commission split frozen from the DelegateProfile contract at snapshot
	// time. Basis points in [0, 10000]. Both default to 10000 when the
	// commission configuration is incomplete.
	BlockCommissionBasisPoints uint64 `protobuf:"varint,1,opt,name=blockCommissionBasisPoints,proto3" json:"blockCommissionBasisPoints,omitempty"`
	EpochCommissionBasisPoints uint64 `protobuf:"varint,2,opt,name=epochCommissionBasisPoints,proto3" json:"epochCommissionBasisPoints,omitempty"`
	// Whether DelegateProfile returned both reward portion fields as
	// non-empty, valid values. This is unrelated to registered(address).
	CommissionConfigured bool `protobuf:"varint,3,opt,name=commissionConfigured,proto3" json:"commissionConfigured,omitempty"`
	// The denominator the drain divides each recomputed voter weight by: the
	// frozen value of the candidate's Votes accumulator at the era boundary.
	// Big-endian unsigned. Zero means the era has no payable voter set for this
	// delegate and its pending pool rolls into a later era.
	TotalWeight []byte `protobuf:"bytes,6,opt,name=totalWeight,proto3" json:"totalWeight,omitempty"`
	// IIP-59: the height this snapshot was frozen at, i.e. the era boundary H.
	// The drain runs several blocks later and must evaluate contract-staking
	// bucket durations against H, not against the block it happens to run in,
	// so H travels with the snapshot rather than being re-derived.
	FreezeHeight uint64 `protobuf:"varint,10,opt,name=freezeHeight,proto3" json:"freezeHeight,omitempty"`
	// IIP-59: the candidate's self-stake bucket index at H. This is the only
	// candidate field the voter-weight recompute reads, so it is frozen as a
	// scalar rather than copy-on-written along with the whole candidate record.
	// math.MaxUint64 means "no self-stake bucket", matching
	// candidateNoSelfStakeBucketIndex.
	SelfStakeBucketIdx uint64 `protobuf:"varint,11,opt,name=selfStakeBucketIdx,proto3" json:"selfStakeBucketIdx,omitempty"`
	// contains filtered or unexported fields
}

IIP-59: per-candidate reward inputs frozen at the reward-era boundary. The rewarding protocol reads this at each epoch close; nothing else mutates it during the reward era, so mid-era DelegateProfile changes do not retroactively re-split rewards.

The snapshot is scalars only. It used to also materialize the delegate's entire (voter, weight) list at every era boundary, which made the boundary cost proportional to the voter population and put a redundant copy of the voter set into consensus state. The drain is voter-major now and recomputes each voter's weight from the era's copy-on-write bucket window, so nothing reads that list.

func (*CandidateRewardSnapshot) Descriptor deprecated

func (*CandidateRewardSnapshot) Descriptor() ([]byte, []int)

Deprecated: Use CandidateRewardSnapshot.ProtoReflect.Descriptor instead.

func (*CandidateRewardSnapshot) GetBlockCommissionBasisPoints

func (x *CandidateRewardSnapshot) GetBlockCommissionBasisPoints() uint64

func (*CandidateRewardSnapshot) GetCommissionConfigured

func (x *CandidateRewardSnapshot) GetCommissionConfigured() bool

func (*CandidateRewardSnapshot) GetEpochCommissionBasisPoints

func (x *CandidateRewardSnapshot) GetEpochCommissionBasisPoints() uint64

func (*CandidateRewardSnapshot) GetFreezeHeight

func (x *CandidateRewardSnapshot) GetFreezeHeight() uint64

func (*CandidateRewardSnapshot) GetSelfStakeBucketIdx

func (x *CandidateRewardSnapshot) GetSelfStakeBucketIdx() uint64

func (*CandidateRewardSnapshot) GetTotalWeight

func (x *CandidateRewardSnapshot) GetTotalWeight() []byte

func (*CandidateRewardSnapshot) ProtoMessage

func (*CandidateRewardSnapshot) ProtoMessage()

func (*CandidateRewardSnapshot) ProtoReflect

func (x *CandidateRewardSnapshot) ProtoReflect() protoreflect.Message

func (*CandidateRewardSnapshot) Reset

func (x *CandidateRewardSnapshot) Reset()

func (*CandidateRewardSnapshot) String

func (x *CandidateRewardSnapshot) String() string

type Candidates

type Candidates struct {
	Candidates []*Candidate `protobuf:"bytes,1,rep,name=candidates,proto3" json:"candidates,omitempty"`
	// contains filtered or unexported fields
}

func (*Candidates) Descriptor deprecated

func (*Candidates) Descriptor() ([]byte, []int)

Deprecated: Use Candidates.ProtoReflect.Descriptor instead.

func (*Candidates) GetCandidates

func (x *Candidates) GetCandidates() []*Candidate

func (*Candidates) ProtoMessage

func (*Candidates) ProtoMessage()

func (*Candidates) ProtoReflect

func (x *Candidates) ProtoReflect() protoreflect.Message

func (*Candidates) Reset

func (x *Candidates) Reset()

func (*Candidates) String

func (x *Candidates) String() string

type ContractBucketRef

type ContractBucketRef struct {
	Contract []byte `protobuf:"bytes,1,opt,name=contract,proto3" json:"contract,omitempty"`
	Index    uint64 `protobuf:"varint,2,opt,name=index,proto3" json:"index,omitempty"`
	// contains filtered or unexported fields
}

IIP-59: one reference to a contract-staking (LSD) bucket. Contract-staking bucket IDs are only unique within a single staking contract, so a reference has to name both. `contract` is the 20-byte address bytes.

func (*ContractBucketRef) Descriptor deprecated

func (*ContractBucketRef) Descriptor() ([]byte, []int)

Deprecated: Use ContractBucketRef.ProtoReflect.Descriptor instead.

func (*ContractBucketRef) GetContract

func (x *ContractBucketRef) GetContract() []byte

func (*ContractBucketRef) GetIndex

func (x *ContractBucketRef) GetIndex() uint64

func (*ContractBucketRef) ProtoMessage

func (*ContractBucketRef) ProtoMessage()

func (*ContractBucketRef) ProtoReflect

func (x *ContractBucketRef) ProtoReflect() protoreflect.Message

func (*ContractBucketRef) Reset

func (x *ContractBucketRef) Reset()

func (*ContractBucketRef) String

func (x *ContractBucketRef) String() string

type ContractBucketRefs

type ContractBucketRefs struct {
	Refs []*ContractBucketRef `protobuf:"bytes,1,rep,name=refs,proto3" json:"refs,omitempty"`
	// contains filtered or unexported fields
}

IIP-59: the set of contract-staking buckets owned by one address, stored in the staking namespace under {LSDVoterIndexPrefix} || owner(20). This is the LSD counterpart of BucketIndices, which can only carry native bucket ids.

Refs are sorted ascending by (contract bytes, index) before serialization so the encoded value is a function of the set alone and never of Go map order.

func (*ContractBucketRefs) Descriptor deprecated

func (*ContractBucketRefs) Descriptor() ([]byte, []int)

Deprecated: Use ContractBucketRefs.ProtoReflect.Descriptor instead.

func (*ContractBucketRefs) GetRefs

func (x *ContractBucketRefs) GetRefs() []*ContractBucketRef

func (*ContractBucketRefs) ProtoMessage

func (*ContractBucketRefs) ProtoMessage()

func (*ContractBucketRefs) ProtoReflect

func (x *ContractBucketRefs) ProtoReflect() protoreflect.Message

func (*ContractBucketRefs) Reset

func (x *ContractBucketRefs) Reset()

func (*ContractBucketRefs) String

func (x *ContractBucketRefs) String() string

type Endorsement

type Endorsement struct {
	ExpireHeight uint64 `protobuf:"varint,1,opt,name=expireHeight,proto3" json:"expireHeight,omitempty"`
	// contains filtered or unexported fields
}

func (*Endorsement) Descriptor deprecated

func (*Endorsement) Descriptor() ([]byte, []int)

Deprecated: Use Endorsement.ProtoReflect.Descriptor instead.

func (*Endorsement) GetExpireHeight

func (x *Endorsement) GetExpireHeight() uint64

func (*Endorsement) ProtoMessage

func (*Endorsement) ProtoMessage()

func (*Endorsement) ProtoReflect

func (x *Endorsement) ProtoReflect() protoreflect.Message

func (*Endorsement) Reset

func (x *Endorsement) Reset()

func (*Endorsement) String

func (x *Endorsement) String() string

type ExitQueue added in v2.4.0

type ExitQueue struct {
	Epoch uint64 `protobuf:"varint,1,opt,name=epoch,proto3" json:"epoch,omitempty"`
	// contains filtered or unexported fields
}

func (*ExitQueue) Descriptor deprecated added in v2.4.0

func (*ExitQueue) Descriptor() ([]byte, []int)

Deprecated: Use ExitQueue.ProtoReflect.Descriptor instead.

func (*ExitQueue) GetEpoch added in v2.4.0

func (x *ExitQueue) GetEpoch() uint64

func (*ExitQueue) ProtoMessage added in v2.4.0

func (*ExitQueue) ProtoMessage()

func (*ExitQueue) ProtoReflect added in v2.4.0

func (x *ExitQueue) ProtoReflect() protoreflect.Message

func (*ExitQueue) Reset added in v2.4.0

func (x *ExitQueue) Reset()

func (*ExitQueue) String added in v2.4.0

func (x *ExitQueue) String() string

type SystemStakingBucket added in v2.3.0

type SystemStakingBucket struct {
	Candidate   string `protobuf:"bytes,1,opt,name=candidate,proto3" json:"candidate,omitempty"`
	Owner       string `protobuf:"bytes,2,opt,name=owner,proto3" json:"owner,omitempty"`
	Amount      string `protobuf:"bytes,3,opt,name=amount,proto3" json:"amount,omitempty"`
	Duration    uint64 `protobuf:"varint,4,opt,name=duration,proto3" json:"duration,omitempty"`
	CreatedAt   uint64 `protobuf:"varint,5,opt,name=createdAt,proto3" json:"createdAt,omitempty"`
	UnlockedAt  uint64 `protobuf:"varint,6,opt,name=unlockedAt,proto3" json:"unlockedAt,omitempty"`
	UnstakedAt  uint64 `protobuf:"varint,7,opt,name=unstakedAt,proto3" json:"unstakedAt,omitempty"`
	Muted       bool   `protobuf:"varint,8,opt,name=muted,proto3" json:"muted,omitempty"`
	Timestamped bool   `protobuf:"varint,9,opt,name=timestamped,proto3" json:"timestamped,omitempty"`
	// contains filtered or unexported fields
}

func (*SystemStakingBucket) Descriptor deprecated added in v2.3.0

func (*SystemStakingBucket) Descriptor() ([]byte, []int)

Deprecated: Use SystemStakingBucket.ProtoReflect.Descriptor instead.

func (*SystemStakingBucket) GetAmount added in v2.3.0

func (x *SystemStakingBucket) GetAmount() string

func (*SystemStakingBucket) GetCandidate added in v2.3.0

func (x *SystemStakingBucket) GetCandidate() string

func (*SystemStakingBucket) GetCreatedAt added in v2.3.0

func (x *SystemStakingBucket) GetCreatedAt() uint64

func (*SystemStakingBucket) GetDuration added in v2.3.0

func (x *SystemStakingBucket) GetDuration() uint64

func (*SystemStakingBucket) GetMuted added in v2.3.0

func (x *SystemStakingBucket) GetMuted() bool

func (*SystemStakingBucket) GetOwner added in v2.3.0

func (x *SystemStakingBucket) GetOwner() string

func (*SystemStakingBucket) GetTimestamped added in v2.3.0

func (x *SystemStakingBucket) GetTimestamped() bool

func (*SystemStakingBucket) GetUnlockedAt added in v2.3.0

func (x *SystemStakingBucket) GetUnlockedAt() uint64

func (*SystemStakingBucket) GetUnstakedAt added in v2.3.0

func (x *SystemStakingBucket) GetUnstakedAt() uint64

func (*SystemStakingBucket) ProtoMessage added in v2.3.0

func (*SystemStakingBucket) ProtoMessage()

func (*SystemStakingBucket) ProtoReflect added in v2.3.0

func (x *SystemStakingBucket) ProtoReflect() protoreflect.Message

func (*SystemStakingBucket) Reset added in v2.3.0

func (x *SystemStakingBucket) Reset()

func (*SystemStakingBucket) String added in v2.3.0

func (x *SystemStakingBucket) String() string

type SystemStakingContract added in v2.3.0

type SystemStakingContract struct {
	NumOfBuckets uint64 `protobuf:"varint,1,opt,name=numOfBuckets,proto3" json:"numOfBuckets,omitempty"`
	// contains filtered or unexported fields
}

func (*SystemStakingContract) Descriptor deprecated added in v2.3.0

func (*SystemStakingContract) Descriptor() ([]byte, []int)

Deprecated: Use SystemStakingContract.ProtoReflect.Descriptor instead.

func (*SystemStakingContract) GetNumOfBuckets added in v2.3.0

func (x *SystemStakingContract) GetNumOfBuckets() uint64

func (*SystemStakingContract) ProtoMessage added in v2.3.0

func (*SystemStakingContract) ProtoMessage()

func (*SystemStakingContract) ProtoReflect added in v2.3.0

func (x *SystemStakingContract) ProtoReflect() protoreflect.Message

func (*SystemStakingContract) Reset added in v2.3.0

func (x *SystemStakingContract) Reset()

func (*SystemStakingContract) String added in v2.3.0

func (x *SystemStakingContract) String() string

type TotalAmount

type TotalAmount struct {
	Amount string `protobuf:"bytes,1,opt,name=amount,proto3" json:"amount,omitempty"`
	Count  uint64 `protobuf:"varint,2,opt,name=count,proto3" json:"count,omitempty"`
	// contains filtered or unexported fields
}

func (*TotalAmount) Descriptor deprecated

func (*TotalAmount) Descriptor() ([]byte, []int)

Deprecated: Use TotalAmount.ProtoReflect.Descriptor instead.

func (*TotalAmount) GetAmount

func (x *TotalAmount) GetAmount() string

func (*TotalAmount) GetCount

func (x *TotalAmount) GetCount() uint64

func (*TotalAmount) ProtoMessage

func (*TotalAmount) ProtoMessage()

func (*TotalAmount) ProtoReflect

func (x *TotalAmount) ProtoReflect() protoreflect.Message

func (*TotalAmount) Reset

func (x *TotalAmount) Reset()

func (*TotalAmount) String

func (x *TotalAmount) String() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL