Documentation ¶
Index ¶
- func NewMsgServiceServer(keeper Keeper) types.MsgServiceServer
- func NewQueryServiceServer(keeper Keeper) types.QueryServiceServer
- type Keeper
- func (k *Keeper) DeleteSession(ctx sdk.Context, id uint64)
- func (k *Keeper) DeleteSessionForAccount(ctx sdk.Context, addr sdk.AccAddress, id uint64)
- func (k *Keeper) DeleteSessionForAllocation(ctx sdk.Context, subscriptionID uint64, addr sdk.AccAddress, sessionID uint64)
- func (k *Keeper) DeleteSessionForInactiveAt(ctx sdk.Context, at time.Time, id uint64)
- func (k *Keeper) DeleteSessionForNode(ctx sdk.Context, addr hubtypes.NodeAddress, id uint64)
- func (k *Keeper) DeleteSessionForSubscription(ctx sdk.Context, subscriptionID, sessionID uint64)
- func (k *Keeper) EndBlock(ctx sdk.Context) []abcitypes.ValidatorUpdate
- func (k *Keeper) GetAccount(ctx sdk.Context, addr sdk.AccAddress) authtypes.AccountI
- func (k *Keeper) GetAllocation(ctx sdk.Context, id uint64, addr sdk.AccAddress) (subscriptiontypes.Allocation, bool)
- func (k *Keeper) GetCount(ctx sdk.Context) uint64
- func (k *Keeper) GetLatestPayoutForAccountByNode(ctx sdk.Context, accAddr sdk.AccAddress, nodeAddr hubtypes.NodeAddress) (subscriptiontypes.Payout, bool)
- func (k *Keeper) GetLatestSessionForAllocation(ctx sdk.Context, subscriptionID uint64, addr sdk.AccAddress) (session types.Session, found bool)
- func (k *Keeper) GetLatestSessionForSubscription(ctx sdk.Context, subscriptionID uint64) (session types.Session, found bool)
- func (k *Keeper) GetNode(ctx sdk.Context, addr hubtypes.NodeAddress) (nodetypes.Node, bool)
- func (k *Keeper) GetParams(ctx sdk.Context) types.Params
- func (k *Keeper) GetPlan(ctx sdk.Context, id uint64) (plantypes.Plan, bool)
- func (k *Keeper) GetSession(ctx sdk.Context, id uint64) (session types.Session, found bool)
- func (k *Keeper) GetSessions(ctx sdk.Context) (items types.Sessions)
- func (k *Keeper) GetSessionsForAccount(ctx sdk.Context, addr sdk.AccAddress) (items types.Sessions)
- func (k *Keeper) GetSessionsForNode(ctx sdk.Context, addr hubtypes.NodeAddress) (items types.Sessions)
- func (k *Keeper) GetSessionsForSubscription(ctx sdk.Context, id uint64) (items types.Sessions)
- func (k *Keeper) GetSubscription(ctx sdk.Context, id uint64) (subscriptiontypes.Subscription, bool)
- func (k *Keeper) HasNodeForPlan(ctx sdk.Context, id uint64, addr hubtypes.NodeAddress) bool
- func (k *Keeper) IterateSessions(ctx sdk.Context, fn func(index int, item types.Session) (stop bool))
- func (k *Keeper) IterateSessionsForAllocation(ctx sdk.Context, id uint64, addr sdk.AccAddress, ...)
- func (k *Keeper) IterateSessionsForInactiveAt(ctx sdk.Context, end time.Time, ...)
- func (k *Keeper) IterateSessionsForSubscription(ctx sdk.Context, id uint64, fn func(index int, item types.Session) (stop bool))
- func (k *Keeper) Logger(ctx sdk.Context) log.Logger
- func (k *Keeper) ProofVerificationEnabled(ctx sdk.Context) (yes bool)
- func (k *Keeper) SendCoinFromDepositToAccount(ctx sdk.Context, from, to sdk.AccAddress, coin sdk.Coin) error
- func (k *Keeper) SendCoinFromDepositToModule(ctx sdk.Context, from sdk.AccAddress, to string, coin sdk.Coin) error
- func (k *Keeper) SetAllocation(ctx sdk.Context, alloc subscriptiontypes.Allocation)
- func (k *Keeper) SetCount(ctx sdk.Context, count uint64)
- func (k *Keeper) SetParams(ctx sdk.Context, params types.Params)
- func (k *Keeper) SetSession(ctx sdk.Context, session types.Session)
- func (k *Keeper) SetSessionForAccount(ctx sdk.Context, addr sdk.AccAddress, id uint64)
- func (k *Keeper) SetSessionForAllocation(ctx sdk.Context, subscriptionID uint64, addr sdk.AccAddress, sessionID uint64)
- func (k *Keeper) SetSessionForInactiveAt(ctx sdk.Context, at time.Time, id uint64)
- func (k *Keeper) SetSessionForNode(ctx sdk.Context, addr hubtypes.NodeAddress, id uint64)
- func (k *Keeper) SetSessionForSubscription(ctx sdk.Context, subscriptionID, sessionID uint64)
- func (k *Keeper) StatusChangeDelay(ctx sdk.Context) (duration time.Duration)
- func (k *Keeper) Store(ctx sdk.Context) sdk.KVStore
- func (k *Keeper) SubscriptionInactivePendingHook(ctx sdk.Context, id uint64) error
- func (k *Keeper) VerifySignature(ctx sdk.Context, addr sdk.AccAddress, proof types.Proof, signature []byte) error
- func (k *Keeper) WithAccountKeeper(keeper expected.AccountKeeper)
- func (k *Keeper) WithBankKeeper(keeper expected.BankKeeper)
- func (k *Keeper) WithDepositKeeper(keeper expected.DepositKeeper)
- func (k *Keeper) WithNodeKeeper(keeper expected.NodeKeeper)
- func (k *Keeper) WithPlanKeeper(keeper expected.PlanKeeper)
- func (k *Keeper) WithSubscriptionKeeper(keeper expected.SubscriptionKeeper)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewMsgServiceServer ¶ added in v0.6.0
func NewMsgServiceServer(keeper Keeper) types.MsgServiceServer
NewMsgServiceServer creates a new instance of `types.MsgServiceServer` using the provided Keeper.
func NewQueryServiceServer ¶ added in v0.6.0
func NewQueryServiceServer(keeper Keeper) types.QueryServiceServer
Types ¶
type Keeper ¶
type Keeper struct {
// contains filtered or unexported fields
}
func NewKeeper ¶
func NewKeeper(cdc codec.BinaryCodec, key sdk.StoreKey, params paramstypes.Subspace, feeCollectorName string) Keeper
func (*Keeper) DeleteSession ¶ added in v0.9.0
func (*Keeper) DeleteSessionForAccount ¶ added in v0.11.0
func (*Keeper) DeleteSessionForAllocation ¶ added in v0.11.0
func (*Keeper) DeleteSessionForInactiveAt ¶ added in v0.11.0
func (*Keeper) DeleteSessionForNode ¶ added in v0.11.0
func (*Keeper) DeleteSessionForSubscription ¶ added in v0.11.0
func (*Keeper) EndBlock ¶ added in v0.11.0
func (k *Keeper) EndBlock(ctx sdk.Context) []abcitypes.ValidatorUpdate
EndBlock is a function that gets called at the end of every block. It processes the inactive sessions and updates their status accordingly. The function returns a slice of ValidatorUpdate, but in this case, it always returns nil.
func (*Keeper) GetAccount ¶ added in v0.5.0
func (*Keeper) GetAllocation ¶ added in v0.11.0
func (k *Keeper) GetAllocation(ctx sdk.Context, id uint64, addr sdk.AccAddress) (subscriptiontypes.Allocation, bool)
func (*Keeper) GetLatestPayoutForAccountByNode ¶ added in v0.11.0
func (k *Keeper) GetLatestPayoutForAccountByNode(ctx sdk.Context, accAddr sdk.AccAddress, nodeAddr hubtypes.NodeAddress) (subscriptiontypes.Payout, bool)
func (*Keeper) GetLatestSessionForAllocation ¶ added in v0.11.0
func (*Keeper) GetLatestSessionForSubscription ¶ added in v0.11.0
func (*Keeper) GetSession ¶
func (*Keeper) GetSessionsForAccount ¶ added in v0.11.0
func (*Keeper) GetSessionsForNode ¶
func (*Keeper) GetSessionsForSubscription ¶
func (*Keeper) GetSubscription ¶
func (k *Keeper) GetSubscription(ctx sdk.Context, id uint64) (subscriptiontypes.Subscription, bool)
func (*Keeper) HasNodeForPlan ¶
func (*Keeper) IterateSessions ¶
func (*Keeper) IterateSessionsForAllocation ¶ added in v0.11.0
func (*Keeper) IterateSessionsForInactiveAt ¶ added in v0.11.0
func (*Keeper) IterateSessionsForSubscription ¶ added in v0.11.0
func (*Keeper) ProofVerificationEnabled ¶ added in v0.5.0
func (*Keeper) SendCoinFromDepositToAccount ¶ added in v0.8.0
func (*Keeper) SendCoinFromDepositToModule ¶ added in v0.10.0
func (*Keeper) SetAllocation ¶ added in v0.11.0
func (k *Keeper) SetAllocation(ctx sdk.Context, alloc subscriptiontypes.Allocation)
func (*Keeper) SetSessionForAccount ¶ added in v0.11.0
func (*Keeper) SetSessionForAllocation ¶ added in v0.11.0
func (*Keeper) SetSessionForInactiveAt ¶ added in v0.11.0
func (*Keeper) SetSessionForNode ¶
func (*Keeper) SetSessionForSubscription ¶
func (*Keeper) StatusChangeDelay ¶ added in v0.11.0
func (*Keeper) SubscriptionInactivePendingHook ¶ added in v0.11.0
func (*Keeper) VerifySignature ¶ added in v0.11.0
func (*Keeper) WithAccountKeeper ¶ added in v0.5.0
func (k *Keeper) WithAccountKeeper(keeper expected.AccountKeeper)
func (*Keeper) WithBankKeeper ¶ added in v0.10.0
func (k *Keeper) WithBankKeeper(keeper expected.BankKeeper)
func (*Keeper) WithDepositKeeper ¶ added in v0.3.1
func (k *Keeper) WithDepositKeeper(keeper expected.DepositKeeper)
func (*Keeper) WithNodeKeeper ¶ added in v0.6.1
func (k *Keeper) WithNodeKeeper(keeper expected.NodeKeeper)
func (*Keeper) WithPlanKeeper ¶
func (k *Keeper) WithPlanKeeper(keeper expected.PlanKeeper)
func (*Keeper) WithSubscriptionKeeper ¶
func (k *Keeper) WithSubscriptionKeeper(keeper expected.SubscriptionKeeper)
Click to show internal directories.
Click to hide internal directories.