Documentation
¶
Index ¶
- Constants
- func NewMsgServerImpl(keeper Keeper) types.MsgServer
- func NewQueryServerImpl(keeper Keeper) types.QueryServer
- type Hooks
- func (h Hooks) AfterBorrowCreated(ctx sdk.Context, borrow types.Borrow)
- func (h Hooks) AfterBorrowModified(ctx sdk.Context, borrow types.Borrow)
- func (h Hooks) AfterDepositCreated(ctx sdk.Context, deposit types.Deposit)
- func (h Hooks) AfterDepositModified(ctx sdk.Context, deposit types.Deposit)
- func (h Hooks) AfterPoolDepositCreated(ctx sdk.Context, poolID string, depositor sdk.AccAddress, _ sdkmath.Int)
- func (h Hooks) BeforeBorrowModified(ctx sdk.Context, borrow types.Borrow)
- func (h Hooks) BeforeDepositModified(ctx sdk.Context, deposit types.Deposit)
- func (h Hooks) BeforePoolDepositModified(ctx sdk.Context, poolID string, depositor sdk.AccAddress, ...)
- type Keeper
- func (k Keeper) AccumulateJoltBorrowRewards(ctx sdk.Context, rewardPeriod types2.MultiRewardPeriod)
- func (k Keeper) AccumulateJoltSupplyRewards(ctx sdk.Context, rewardPeriod types2.MultiRewardPeriod)
- func (k Keeper) AccumulateSwapRewards(ctx sdk.Context, rewardPeriod types.MultiRewardPeriod)
- func (k Keeper) CalculateRewards(oldIndexes, newIndexes types2.RewardIndexes, sourceShares sdk.Dec) (sdk.Coins, error)
- func (k Keeper) CalculateSingleReward(oldIndex, newIndex, sourceShares sdk.Dec) (sdk.Int, error)
- func (k Keeper) ClaimJoltReward(ctx sdk.Context, owner, receiver sdk.AccAddress, denom string, ...) error
- func (k Keeper) ClaimSwapReward(ctx sdk.Context, owner, receiver sdk.AccAddress, denom string, ...) error
- func (k Keeper) DeleteJoltLiquidityProviderClaim(ctx sdk.Context, owner sdk.AccAddress)
- func (k Keeper) DeleteSwapClaim(ctx sdk.Context, owner sdk.AccAddress)
- func (k Keeper) GetAllJoltLiquidityProviderClaims(ctx sdk.Context) types.JoltLiquidityProviderClaims
- func (k Keeper) GetAllSwapClaims(ctx sdk.Context) types.SwapClaims
- func (k Keeper) GetClaimEnd(ctx sdk.Context) time.Time
- func (k Keeper) GetJoltBorrowRewardIndexes(ctx sdk.Context, denom string) (types.RewardIndexes, bool)
- func (k Keeper) GetJoltBorrowRewardPeriods(ctx sdk.Context, denom string) (types.MultiRewardPeriod, bool)
- func (k Keeper) GetJoltLiquidityProviderClaim(ctx sdk.Context, addr sdk.AccAddress) (types.JoltLiquidityProviderClaim, bool)
- func (k Keeper) GetJoltSupplyRewardIndexes(ctx sdk.Context, denom string) (types.RewardIndexes, bool)
- func (k Keeper) GetJoltSupplyRewardPeriods(ctx sdk.Context, denom string) (types.MultiRewardPeriod, bool)
- func (k Keeper) GetMultiplierByDenom(ctx sdk.Context, denom string, name string) (types.Multiplier, bool)
- func (k Keeper) GetParams(ctx sdk.Context) types.Params
- func (k Keeper) GetPeriodLength(blockTime time.Time, monthsLockup int64) int64
- func (k Keeper) GetPreviousDelegatorRewardAccrualTime(ctx sdk.Context, denom string) (blockTime time.Time, found bool)
- func (k Keeper) GetPreviousJoltBorrowRewardAccrualTime(ctx sdk.Context, denom string) (blockTime time.Time, found bool)
- func (k Keeper) GetPreviousJoltSupplyRewardAccrualTime(ctx sdk.Context, denom string) (blockTime time.Time, found bool)
- func (k Keeper) GetSwapClaim(ctx sdk.Context, addr sdk.AccAddress) (types.SwapClaim, bool)
- func (k Keeper) GetSwapRewardAccrualTime(ctx sdk.Context, poolID string) (blockTime time.Time, found bool)
- func (k Keeper) GetSwapRewardIndexes(ctx sdk.Context, poolID string) (types.RewardIndexes, bool)
- func (k Keeper) GetSynchronizedSwapClaim(ctx sdk.Context, owner sdk.AccAddress) (types.SwapClaim, bool)
- func (k Keeper) Hooks() Hooks
- func (k Keeper) InitializeJoltBorrowReward(ctx sdk.Context, borrow jolttypes.Borrow)
- func (k Keeper) InitializeJoltSupplyReward(ctx sdk.Context, deposit hardtypes.Deposit)
- func (k Keeper) InitializeSwapReward(ctx sdk.Context, poolID string, owner sdk.AccAddress)
- func (k Keeper) IterateJoltBorrowRewardAccrualTimes(ctx sdk.Context, cb func(string, time.Time) (stop bool))
- func (k Keeper) IterateJoltBorrowRewardIndexes(ctx sdk.Context, ...)
- func (k Keeper) IterateJoltLiquidityProviderClaims(ctx sdk.Context, cb func(c types.JoltLiquidityProviderClaim) (stop bool))
- func (k Keeper) IterateJoltSupplyRewardAccrualTimes(ctx sdk.Context, cb func(string, time.Time) (stop bool))
- func (k Keeper) IterateJoltSupplyRewardIndexes(ctx sdk.Context, ...)
- func (k Keeper) IterateSwapClaims(ctx sdk.Context, cb func(c types.SwapClaim) (stop bool))
- func (k Keeper) IterateSwapRewardAccrualTimes(ctx sdk.Context, cb func(string, time.Time) (stop bool))
- func (k Keeper) IterateSwapRewardIndexes(ctx sdk.Context, ...)
- func (k Keeper) SendTimeLockedCoinsToAccount(ctx sdk.Context, senderModule string, recipientAddr sdk.AccAddress, ...) error
- func (k Keeper) SendTimeLockedCoinsToBaseAccount(ctx sdk.Context, senderModule string, recipientAddr sdk.AccAddress, ...) error
- func (k Keeper) SendTimeLockedCoinsToPeriodicVestingAccount(ctx sdk.Context, senderModule string, recipientAddr sdk.AccAddress, ...) error
- func (k Keeper) SetJoltBorrowRewardIndexes(ctx sdk.Context, denom string, indexes types.RewardIndexes)
- func (k Keeper) SetJoltLiquidityProviderClaim(ctx sdk.Context, c types.JoltLiquidityProviderClaim)
- func (k Keeper) SetJoltSupplyRewardIndexes(ctx sdk.Context, denom string, indexes types.RewardIndexes)
- func (k Keeper) SetParams(ctx sdk.Context, params types.Params)
- func (k Keeper) SetPreviousDelegatorRewardAccrualTime(ctx sdk.Context, denom string, blockTime time.Time)
- func (k Keeper) SetPreviousJoltBorrowRewardAccrualTime(ctx sdk.Context, denom string, blockTime time.Time)
- func (k Keeper) SetPreviousJoltSupplyRewardAccrualTime(ctx sdk.Context, denom string, blockTime time.Time)
- func (k Keeper) SetSwapClaim(ctx sdk.Context, c types.SwapClaim)
- func (k Keeper) SetSwapRewardAccrualTime(ctx sdk.Context, poolID string, blockTime time.Time)
- func (k Keeper) SetSwapRewardIndexes(ctx sdk.Context, poolID string, indexes types.RewardIndexes)
- func (k Keeper) SimulateJoltSynchronization(ctx sdk.Context, claim types2.JoltLiquidityProviderClaim) types2.JoltLiquidityProviderClaim
- func (k Keeper) SynchronizeJoltBorrowReward(ctx sdk.Context, borrow jolttypes.Borrow)
- func (k Keeper) SynchronizeJoltLiquidityProviderClaim(ctx sdk.Context, owner sdk.AccAddress)
- func (k Keeper) SynchronizeJoltSupplyReward(ctx sdk.Context, deposit hardtypes.Deposit)
- func (k Keeper) SynchronizeSwapReward(ctx sdk.Context, poolID string, owner sdk.AccAddress, shares sdkmath.Int)
- func (k Keeper) UpdateJoltBorrowIndexDenoms(ctx sdk.Context, borrow jolttypes.Borrow)
- func (k Keeper) UpdateJoltSupplyIndexDenoms(ctx sdk.Context, deposit hardtypes.Deposit)
- type Migrator
Constants ¶
const ( // BeginningOfMonth harvest rewards that are claimed after the 15th at 14:00UTC of the month always vest on the first of the month BeginningOfMonth = 1 // MidMonth harvest rewards that are claimed before the 15th at 14:00UTC of the month always vest on the 15 of the month MidMonth = 15 // PaymentHour harvest rewards always vest at 14:00UTC PaymentHour = 14 )
const (
RewardTypeJolt = "jolt"
)
Variables ¶
This section is empty.
Functions ¶
func NewMsgServerImpl ¶
NewMsgServerImpl returns an implementation of the incentive MsgServer interface for the provided Keeper.
func NewQueryServerImpl ¶ added in v0.0.5
func NewQueryServerImpl(keeper Keeper) types.QueryServer
NewQueryServerImpl creates a new server for handling gRPC queries.
Types ¶
type Hooks ¶
type Hooks struct {
// contains filtered or unexported fields
}
Hooks wrapper struct for hooks
func (Hooks) AfterBorrowCreated ¶
AfterBorrowCreated function that runs after a borrow is created
func (Hooks) AfterBorrowModified ¶
AfterBorrowModified function that runs after a borrow is modified
func (Hooks) AfterDepositCreated ¶
AfterDepositCreated function that runs after a deposit is created
func (Hooks) AfterDepositModified ¶
AfterDepositModified function that runs after a deposit is modified
func (Hooks) AfterPoolDepositCreated ¶ added in v0.0.8
func (Hooks) BeforeBorrowModified ¶
BeforeBorrowModified function that runs before a borrow is modified
func (Hooks) BeforeDepositModified ¶
BeforeDepositModified function that runs before a deposit is modified
func (Hooks) BeforePoolDepositModified ¶ added in v0.0.8
type Keeper ¶
type Keeper struct {
// contains filtered or unexported fields
}
Keeper keeper for the incentive module
func NewKeeper ¶
func NewKeeper( cdc codec.Codec, key storetypes.StoreKey, paramstore types.ParamSubspace, bk types.BankKeeper, joltKeeper types.JoltKeeper, ak types.AccountKeeper, swapKeeper types.SwapKeeper, ) Keeper
NewKeeper creates a new keeper
func (Keeper) AccumulateJoltBorrowRewards ¶
func (k Keeper) AccumulateJoltBorrowRewards(ctx sdk.Context, rewardPeriod types2.MultiRewardPeriod)
AccumulateJoltBorrowRewards calculates new rewards to distribute this block and updates the global indexes to reflect this. The provided rewardPeriod must be valid to avoid panics in calculating time durations.
func (Keeper) AccumulateJoltSupplyRewards ¶
func (k Keeper) AccumulateJoltSupplyRewards(ctx sdk.Context, rewardPeriod types2.MultiRewardPeriod)
AccumulateJoltSupplyRewards calculates new rewards to distribute this block and updates the global indexes to reflect this. The provided rewardPeriod must be valid to avoid panics in calculating time durations.
func (Keeper) AccumulateSwapRewards ¶ added in v0.0.8
func (k Keeper) AccumulateSwapRewards(ctx sdk.Context, rewardPeriod types.MultiRewardPeriod)
AccumulateSwapRewards calculates new rewards to distribute this block and updates the global indexes to reflect this. The provided rewardPeriod must be valid to avoid panics in calculating time durations.
func (Keeper) CalculateRewards ¶
func (k Keeper) CalculateRewards(oldIndexes, newIndexes types2.RewardIndexes, sourceShares sdk.Dec) (sdk.Coins, error)
CalculateRewards computes how much rewards should have accrued to a reward source (eg a user's jolt borrowed btc amount) between two index values.
oldIndex is normally the index stored on a claim, newIndex the current global value, and sourceShares a jolt borrowed/supplied amount.
It returns an error if newIndexes does not contain all CollateralTypes from oldIndexes, or if any value of oldIndex.RewardFactor > newIndex.RewardFactor. This should never happen, as it would mean that a global reward index has decreased in value, or that a global reward index has been deleted from state.
func (Keeper) CalculateSingleReward ¶
CalculateSingleReward computes how much rewards should have accrued to a reward source (eg a user's btcb-a cdp principal) between two index values.
oldIndex is normally the index stored on a claim, newIndex the current global value, and sourceShares a cdp principal amount.
Returns an error if oldIndex > newIndex. This should never happen, as it would mean that a global reward index has decreased in value, or that a global reward index has been deleted from state.
func (Keeper) ClaimJoltReward ¶
func (k Keeper) ClaimJoltReward(ctx sdk.Context, owner, receiver sdk.AccAddress, denom string, multiplierName string) error
ClaimJoltReward pays out funds from a claim to a receiver account. Rewards are removed from a claim and paid out according to the multiplier, which reduces the reward amount in exchange for shorter vesting times.
func (Keeper) ClaimSwapReward ¶ added in v0.0.8
func (k Keeper) ClaimSwapReward(ctx sdk.Context, owner, receiver sdk.AccAddress, denom string, multiplierName string) error
ClaimSwapReward pays out funds from a claim to a receiver account. Rewards are removed from a claim and paid out according to the multiplier, which reduces the reward amount in exchange for shorter vesting times.
func (Keeper) DeleteJoltLiquidityProviderClaim ¶
func (k Keeper) DeleteJoltLiquidityProviderClaim(ctx sdk.Context, owner sdk.AccAddress)
DeleteJoltLiquidityProviderClaim deletes the claim in the store corresponding to the input address, collateral type, and id
func (Keeper) DeleteSwapClaim ¶
func (k Keeper) DeleteSwapClaim(ctx sdk.Context, owner sdk.AccAddress)
DeleteSwapClaim deletes the claim in the store corresponding to the input address.
func (Keeper) GetAllJoltLiquidityProviderClaims ¶
func (k Keeper) GetAllJoltLiquidityProviderClaims(ctx sdk.Context) types.JoltLiquidityProviderClaims
GetAllJoltLiquidityProviderClaims returns all Claim objects in the store
func (Keeper) GetAllSwapClaims ¶
func (k Keeper) GetAllSwapClaims(ctx sdk.Context) types.SwapClaims
GetAllSwapClaims returns all Claim objects in the store
func (Keeper) GetClaimEnd ¶
GetClaimEnd returns the claim end time for the params
func (Keeper) GetJoltBorrowRewardIndexes ¶
func (k Keeper) GetJoltBorrowRewardIndexes(ctx sdk.Context, denom string) (types.RewardIndexes, bool)
GetJoltBorrowRewardIndexes gets the current reward indexes for an individual denom
func (Keeper) GetJoltBorrowRewardPeriods ¶
func (k Keeper) GetJoltBorrowRewardPeriods(ctx sdk.Context, denom string) (types.MultiRewardPeriod, bool)
GetJoltBorrowRewardPeriods returns the reward period with the specified collateral type if it's found in the params
func (Keeper) GetJoltLiquidityProviderClaim ¶
func (k Keeper) GetJoltLiquidityProviderClaim(ctx sdk.Context, addr sdk.AccAddress) (types.JoltLiquidityProviderClaim, bool)
GetJoltLiquidityProviderClaim returns the claim in the store corresponding the the input address collateral type and id and a boolean for if the claim was found
func (Keeper) GetJoltSupplyRewardIndexes ¶
func (k Keeper) GetJoltSupplyRewardIndexes(ctx sdk.Context, denom string) (types.RewardIndexes, bool)
GetJoltSupplyRewardIndexes gets the current reward indexes for an individual denom
func (Keeper) GetJoltSupplyRewardPeriods ¶
func (k Keeper) GetJoltSupplyRewardPeriods(ctx sdk.Context, denom string) (types.MultiRewardPeriod, bool)
GetJoltSupplyRewardPeriods returns the reward period with the specified collateral type if it's found in the params
func (Keeper) GetMultiplierByDenom ¶
func (k Keeper) GetMultiplierByDenom(ctx sdk.Context, denom string, name string) (types.Multiplier, bool)
GetMultiplierByDenom fetches a multiplier from the params matching the denom and name.
func (Keeper) GetPeriodLength ¶
GetPeriodLength returns the length of the lockup period based on the input blocktime and multiplier lockup. Note that pay dates are always the 1st or 15th of the month at 14:00UTC. Months lockup cannot be negative
func (Keeper) GetPreviousDelegatorRewardAccrualTime ¶
func (k Keeper) GetPreviousDelegatorRewardAccrualTime(ctx sdk.Context, denom string) (blockTime time.Time, found bool)
GetPreviousDelegatorRewardAccrualTime returns the last time a denom accrued protocol delegator rewards
func (Keeper) GetPreviousJoltBorrowRewardAccrualTime ¶
func (k Keeper) GetPreviousJoltBorrowRewardAccrualTime(ctx sdk.Context, denom string) (blockTime time.Time, found bool)
GetPreviousJoltBorrowRewardAccrualTime returns the last time a denom accrued Hard protocol borrow-side rewards
func (Keeper) GetPreviousJoltSupplyRewardAccrualTime ¶
func (k Keeper) GetPreviousJoltSupplyRewardAccrualTime(ctx sdk.Context, denom string) (blockTime time.Time, found bool)
GetPreviousJoltSupplyRewardAccrualTime returns the last time a denom accrued Hard protocol supply-side rewards
func (Keeper) GetSwapClaim ¶
GetSwapClaim returns the claim in the store corresponding the the input address.
func (Keeper) GetSwapRewardAccrualTime ¶
func (k Keeper) GetSwapRewardAccrualTime(ctx sdk.Context, poolID string) (blockTime time.Time, found bool)
GetSwapRewardAccrualTime fetches the last time rewards were accrued for a swap pool.
func (Keeper) GetSwapRewardIndexes ¶
GetSwapRewardIndexes fetches the global reward indexes that track total rewards to a swap pool.
func (Keeper) GetSynchronizedSwapClaim ¶ added in v0.0.8
func (k Keeper) GetSynchronizedSwapClaim(ctx sdk.Context, owner sdk.AccAddress) (types.SwapClaim, bool)
GetSynchronizedSwapClaim fetches a swap claim from the store and syncs rewards for all rewarded pools.
func (Keeper) InitializeJoltBorrowReward ¶
InitializeJoltBorrowReward initializes the borrow-side of a jolt liquidity provider claim by creating the claim and setting the borrow reward factor index
func (Keeper) InitializeJoltSupplyReward ¶
InitializeJoltSupplyReward initializes the supply-side of a jolt liquidity provider claim by creating the claim and setting the supply reward factor index
func (Keeper) InitializeSwapReward ¶ added in v0.0.8
InitializeSwapReward creates a new claim with zero rewards and indexes matching the global indexes. If the claim already exists it just updates the indexes.
func (Keeper) IterateJoltBorrowRewardAccrualTimes ¶
func (Keeper) IterateJoltBorrowRewardIndexes ¶
func (k Keeper) IterateJoltBorrowRewardIndexes(ctx sdk.Context, cb func(denom string, indexes types.RewardIndexes) (stop bool))
IterateJoltBorrowRewardIndexes iterates over all Hard borrow reward index objects in the store and preforms a callback function
func (Keeper) IterateJoltLiquidityProviderClaims ¶
func (k Keeper) IterateJoltLiquidityProviderClaims(ctx sdk.Context, cb func(c types.JoltLiquidityProviderClaim) (stop bool))
IterateJoltLiquidityProviderClaims iterates over all claim objects in the store and preforms a callback function
func (Keeper) IterateJoltSupplyRewardAccrualTimes ¶
func (Keeper) IterateJoltSupplyRewardIndexes ¶
func (k Keeper) IterateJoltSupplyRewardIndexes(ctx sdk.Context, cb func(denom string, indexes types.RewardIndexes) (stop bool))
IterateJoltSupplyRewardIndexes iterates over all Hard supply reward index objects in the store and preforms a callback function
func (Keeper) IterateSwapClaims ¶
IterateSwapClaims iterates over all claim objects in the store and preforms a callback function
func (Keeper) IterateSwapRewardAccrualTimes ¶
func (Keeper) IterateSwapRewardIndexes ¶
func (k Keeper) IterateSwapRewardIndexes(ctx sdk.Context, cb func(poolID string, indexes types.RewardIndexes) (stop bool))
IterateSwapRewardIndexes iterates over all swap reward index objects in the store and preforms a callback function
func (Keeper) SendTimeLockedCoinsToAccount ¶
func (k Keeper) SendTimeLockedCoinsToAccount(ctx sdk.Context, senderModule string, recipientAddr sdk.AccAddress, amt sdk.Coins, length int64) error
SendTimeLockedCoinsToAccount sends time-locked coins from the input module account to the recipient. If the recipients account is not a vesting account and the input length is greater than zero, the recipient account is converted to a periodic vesting account and the coins are added to the vesting balance as a vesting period with the input length.
func (Keeper) SendTimeLockedCoinsToBaseAccount ¶
func (k Keeper) SendTimeLockedCoinsToBaseAccount(ctx sdk.Context, senderModule string, recipientAddr sdk.AccAddress, amt sdk.Coins, length int64) error
SendTimeLockedCoinsToBaseAccount sends time-locked coins from the input module account to the recipient, converting the recipient account to a vesting account
func (Keeper) SendTimeLockedCoinsToPeriodicVestingAccount ¶
func (k Keeper) SendTimeLockedCoinsToPeriodicVestingAccount(ctx sdk.Context, senderModule string, recipientAddr sdk.AccAddress, amt sdk.Coins, length int64) error
SendTimeLockedCoinsToPeriodicVestingAccount sends time-locked coins from the input module account to the recipient
func (Keeper) SetJoltBorrowRewardIndexes ¶
func (k Keeper) SetJoltBorrowRewardIndexes(ctx sdk.Context, denom string, indexes types.RewardIndexes)
SetJoltBorrowRewardIndexes sets the current reward indexes for an individual denom
func (Keeper) SetJoltLiquidityProviderClaim ¶
func (k Keeper) SetJoltLiquidityProviderClaim(ctx sdk.Context, c types.JoltLiquidityProviderClaim)
SetJoltLiquidityProviderClaim sets the claim in the store corresponding to the input address, collateral type, and id
func (Keeper) SetJoltSupplyRewardIndexes ¶
func (k Keeper) SetJoltSupplyRewardIndexes(ctx sdk.Context, denom string, indexes types.RewardIndexes)
SetJoltSupplyRewardIndexes sets the current reward indexes for an individual denom
func (Keeper) SetPreviousDelegatorRewardAccrualTime ¶
func (k Keeper) SetPreviousDelegatorRewardAccrualTime(ctx sdk.Context, denom string, blockTime time.Time)
SetPreviousDelegatorRewardAccrualTime sets the last time a denom accrued protocol delegator rewards
func (Keeper) SetPreviousJoltBorrowRewardAccrualTime ¶
func (k Keeper) SetPreviousJoltBorrowRewardAccrualTime(ctx sdk.Context, denom string, blockTime time.Time)
SetPreviousJoltBorrowRewardAccrualTime sets the last time a denom accrued Hard protocol borrow-side rewards
func (Keeper) SetPreviousJoltSupplyRewardAccrualTime ¶
func (k Keeper) SetPreviousJoltSupplyRewardAccrualTime(ctx sdk.Context, denom string, blockTime time.Time)
SetPreviousJoltSupplyRewardAccrualTime sets the last time a denom accrued Hard protocol supply-side rewards
func (Keeper) SetSwapClaim ¶
SetSwapClaim sets the claim in the store corresponding to the input address.
func (Keeper) SetSwapRewardAccrualTime ¶
SetSwapRewardAccrualTime stores the last time rewards were accrued for a swap pool.
func (Keeper) SetSwapRewardIndexes ¶
SetSwapRewardIndexes stores the global reward indexes that track total rewards to a swap pool.
func (Keeper) SimulateJoltSynchronization ¶
func (k Keeper) SimulateJoltSynchronization(ctx sdk.Context, claim types2.JoltLiquidityProviderClaim) types2.JoltLiquidityProviderClaim
SimulateJoltSynchronization calculates a user's outstanding jolt rewards by simulating reward synchronization
func (Keeper) SynchronizeJoltBorrowReward ¶
SynchronizeJoltBorrowReward updates the claim object by adding any accumulated rewards and updating the reward index value
func (Keeper) SynchronizeJoltLiquidityProviderClaim ¶
func (k Keeper) SynchronizeJoltLiquidityProviderClaim(ctx sdk.Context, owner sdk.AccAddress)
SynchronizeJoltLiquidityProviderClaim adds any accumulated rewards
func (Keeper) SynchronizeJoltSupplyReward ¶
SynchronizeJoltSupplyReward updates the claim object by adding any accumulated rewards and updating the reward index value
func (Keeper) SynchronizeSwapReward ¶ added in v0.0.8
func (k Keeper) SynchronizeSwapReward(ctx sdk.Context, poolID string, owner sdk.AccAddress, shares sdkmath.Int)
SynchronizeSwapReward updates the claim object by adding any accumulated rewards and updating the reward index value.
func (Keeper) UpdateJoltBorrowIndexDenoms ¶
UpdateJoltBorrowIndexDenoms adds or removes reward indexes from a claim to match the denoms in the borrow.
type Migrator ¶ added in v0.0.6
type Migrator struct {
// contains filtered or unexported fields
}
Migrator is a struct for handling in-place store migrations.
func NewMigrator ¶ added in v0.0.6
NewMigrator returns a new Migrator.