Documentation ¶
Index ¶
- func NewMsgServerImpl(keeper Keeper) types.MsgServer
- func PublicKeyToHex(pubKey crypto.PubKey) string
- type Delegation
- type HeartbeatManager
- type Keeper
- func (k Keeper) AddUnbondingEntry(ctx context.Context, entry types.UnbondingEntry) error
- func (k Keeper) AllDelegations(ctx context.Context, req *types.QueryAllDelegationsRequest) (*types.QueryAllDelegationsResponse, error)
- func (k Keeper) DelegateTokens(ctx context.Context, delegator sdk.AccAddress, amount sdkmath.Int) error
- func (k Keeper) DelegatedAmount(goCtx context.Context, req *types.QueryDelegatedAmountRequest) (*types.QueryDelegatedAmountResponse, error)
- func (k Keeper) GetBankKeeper() types.BankKeeper
- func (k Keeper) GetBondingPrefix() string
- func (k Keeper) GetDelegatedAmount(ctx context.Context, delegator sdk.AccAddress) sdkmath.Int
- func (k Keeper) GetLockedBalance(ctx context.Context, delegator sdk.AccAddress) sdkmath.Int
- func (k Keeper) GetParams(ctx sdk.Context) types.Params
- func (k Keeper) GetPublicKeyForDelegator(ctx context.Context, delegator sdk.AccAddress) (string, error)
- func (k Keeper) GetStoreKey() storetypes.StoreKey
- func (k Keeper) GetStoreService() store.KVStoreService
- func (k Keeper) Logger(ctx sdk.Context) log.Logger
- func (k Keeper) Params(goCtx context.Context, req *types.QueryParamsRequest) (*types.QueryParamsResponse, error)
- func (k Keeper) QueryAllDelegations(ctx context.Context) ([]types.DelegationInfo, error)
- func (k Keeper) SetDelegatedAmount(ctx context.Context, delegator sdk.AccAddress, amount sdkmath.Int)
- func (k Keeper) SetLockedBalance(ctx context.Context, delegator sdk.AccAddress, amount sdkmath.Int, ...)
- func (k Keeper) SetParams(ctx sdk.Context, params types.Params)
- func (k *Keeper) StartHeartbeatTimer(ctx sdk.Context)
- func (k Keeper) UnbondingEntries(goCtx context.Context, req *types.QueryUnbondingEntriesRequest) (*types.QueryUnbondingEntriesResponse, error)
- func (k Keeper) UndelegateTokens(ctx context.Context, account sdk.AccAddress, amount sdkmath.Int) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewMsgServerImpl ¶
NewMsgServerImpl returns an implementation of the MsgServer interface for the provided Keeper.
func PublicKeyToHex ¶
Types ¶
type Delegation ¶
type HeartbeatManager ¶
type HeartbeatManager struct { Keeper *Keeper // contains filtered or unexported fields }
func NewHeartbeatManager ¶
func NewHeartbeatManager(storeService store.KVStoreService, keeper *Keeper) *HeartbeatManager
func (*HeartbeatManager) GetDelegationData ¶
func (hm *HeartbeatManager) GetDelegationData(ctx sdk.Context) ([]Delegation, error)
func (*HeartbeatManager) SendHeartbeatIfDataChanged ¶
func (hm *HeartbeatManager) SendHeartbeatIfDataChanged(ctx sdk.Context, data []Delegation) error
func (*HeartbeatManager) StartHeartbeatTimer ¶
func (hm *HeartbeatManager) StartHeartbeatTimer(ctx sdk.Context)
type Keeper ¶
type Keeper struct {
// contains filtered or unexported fields
}
func NewKeeper ¶
func NewKeeper( cdc codec.BinaryCodec, ps paramtypes.Subspace, bk types.BankKeeper, authority string, storeService store.KVStoreService, ak types.AccountKeeper, ) *Keeper
func (Keeper) AddUnbondingEntry ¶
AddUnbondingEntry adds a new unbonding entry for a given account.
func (Keeper) AllDelegations ¶
func (k Keeper) AllDelegations(ctx context.Context, req *types.QueryAllDelegationsRequest) (*types.QueryAllDelegationsResponse, error)
AllDelegations implements the QueryServer.AllDelegations method
func (Keeper) DelegateTokens ¶
func (k Keeper) DelegateTokens(ctx context.Context, delegator sdk.AccAddress, amount sdkmath.Int) error
DelegateTokens locks the tokens for gridnode delegation
func (Keeper) DelegatedAmount ¶
func (k Keeper) DelegatedAmount(goCtx context.Context, req *types.QueryDelegatedAmountRequest) (*types.QueryDelegatedAmountResponse, error)
func (Keeper) GetBankKeeper ¶
func (k Keeper) GetBankKeeper() types.BankKeeper
func (Keeper) GetBondingPrefix ¶
func (Keeper) GetDelegatedAmount ¶
func (Keeper) GetLockedBalance ¶
func (Keeper) GetPublicKeyForDelegator ¶
func (Keeper) GetStoreKey ¶
func (k Keeper) GetStoreKey() storetypes.StoreKey
func (Keeper) GetStoreService ¶
func (k Keeper) GetStoreService() store.KVStoreService
func (Keeper) Params ¶
func (k Keeper) Params(goCtx context.Context, req *types.QueryParamsRequest) (*types.QueryParamsResponse, error)
func (Keeper) QueryAllDelegations ¶
func (Keeper) SetDelegatedAmount ¶
func (Keeper) SetLockedBalance ¶
func (*Keeper) StartHeartbeatTimer ¶
func (Keeper) UnbondingEntries ¶
func (k Keeper) UnbondingEntries(goCtx context.Context, req *types.QueryUnbondingEntriesRequest) (*types.QueryUnbondingEntriesResponse, error)
func (Keeper) UndelegateTokens ¶
func (k Keeper) UndelegateTokens(ctx context.Context, account sdk.AccAddress, amount sdkmath.Int) error
UndelegateTokens unlocks the tokens from gridnode delegation
Click to show internal directories.
Click to hide internal directories.