keeper

package
v0.38.0 Latest Latest
Warning

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

Go to latest
Published: Jul 15, 2024 License: Apache-2.0 Imports: 23 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BeginBlockerProcessMTP

func BeginBlockerProcessMTP(ctx sdk.Context, k Keeper, mtp *types.MTP, pool types.Pool, ammPool ammtypes.Pool, baseCurrency string, baseCurrencyDecimal uint64) error

func NewMsgServerImpl

func NewMsgServerImpl(keeper Keeper) types.MsgServer

NewMsgServerImpl returns an implementation of the MsgServer interface for the provided Keeper.

Types

type AmmHooks

type AmmHooks struct {
	// contains filtered or unexported fields
}

Hooks wrapper struct for tvl keeper

func (AmmHooks) AfterExitPool

func (h AmmHooks) AfterExitPool(ctx sdk.Context, sender sdk.AccAddress, pool ammtypes.Pool, shareInAmount math.Int, exitCoins sdk.Coins) error

AfterExitPool is called after ExitPool, ExitSwapShareAmountIn, and ExitSwapExternAmountOut

func (AmmHooks) AfterJoinPool

func (h AmmHooks) AfterJoinPool(ctx sdk.Context, sender sdk.AccAddress, pool ammtypes.Pool, enterCoins sdk.Coins, shareOutAmount math.Int)

AfterJoinPool is called after JoinPool, JoinSwapExternAmountIn, and JoinSwapShareAmountOut

func (AmmHooks) AfterPoolCreated

func (h AmmHooks) AfterPoolCreated(ctx sdk.Context, sender sdk.AccAddress, pool ammtypes.Pool)

AfterPoolCreated is called after CreatePool

func (AmmHooks) AfterSwap

func (h AmmHooks) AfterSwap(ctx sdk.Context, sender sdk.AccAddress, pool ammtypes.Pool, input sdk.Coins, output sdk.Coins) error

AfterSwap is called after SwapExactAmountIn and SwapExactAmountOut

type Hooks

type Hooks struct {
	// contains filtered or unexported fields
}

Hooks wrapper struct for incentive keeper

func (Hooks) AfterEpochEnd

func (h Hooks) AfterEpochEnd(ctx sdk.Context, epochIdentifier string, epochNumber int64)

AfterEpochEnd implements EpochHooks

func (Hooks) BeforeEpochStart

func (h Hooks) BeforeEpochStart(ctx sdk.Context, epochIdentifier string, epochNumber int64)

BeforeEpochStart implements EpochHooks

type Keeper

func NewKeeper

func NewKeeper(
	cdc codec.BinaryCodec,
	storeKey,
	memKey storetypes.StoreKey,
	authority string,
	amm types.AmmKeeper,
	bk types.BankKeeper,
	oracleKeeper ammtypes.OracleKeeper,
	assetProfileKeeper types.AssetProfileKeeper,
	parameterKeeper *pkeeper.Keeper,
) *Keeper

func (Keeper) AddCollateralToMtp added in v0.35.0

func (k Keeper) AddCollateralToMtp(ctx sdk.Context, msg *types.MsgAddCollateral) (*types.MsgAddCollateralResponse, error)

func (Keeper) AfterEpochEnd

func (k Keeper) AfterEpochEnd(ctx sdk.Context, epochIdentifier string, _ int64)

AfterEpochEnd distributes vested tokens at the end of each epoch

func (Keeper) AfterExitPool

func (k Keeper) AfterExitPool(ctx sdk.Context, sender sdk.AccAddress, ammPool ammtypes.Pool, shareInAmount math.Int, exitCoins sdk.Coins) error

AfterExitPool is called after ExitPool, ExitSwapShareAmountIn, and ExitSwapExternAmountOut

func (Keeper) AfterJoinPool

func (k Keeper) AfterJoinPool(ctx sdk.Context, sender sdk.AccAddress, ammPool ammtypes.Pool, enterCoins sdk.Coins, shareOutAmount math.Int)

AfterJoinPool is called after JoinPool, JoinSwapExternAmountIn, and JoinSwapShareAmountOut

func (Keeper) AfterPoolCreated

func (k Keeper) AfterPoolCreated(ctx sdk.Context, sender sdk.AccAddress, ammPool ammtypes.Pool)

AfterPoolCreated is called after CreatePool

func (Keeper) AfterSwap

func (k Keeper) AfterSwap(ctx sdk.Context, sender sdk.AccAddress, ammPool ammtypes.Pool, input sdk.Coins, output sdk.Coins) error

AfterSwap is called after SwapExactAmountIn and SwapExactAmountOut

func (Keeper) AmmHooks

func (k Keeper) AmmHooks() AmmHooks

Return the wrapper struct

func (Keeper) AmmPoolBalanceCheck

func (k Keeper) AmmPoolBalanceCheck(ctx sdk.Context, poolId uint64) error

func (Keeper) BeforeEpochStart

func (k Keeper) BeforeEpochStart(ctx sdk.Context, epochIdentifier string, epochNumber int64)

BeforeEpochStart performs a no-op

func (Keeper) BeginBlocker

func (k Keeper) BeginBlocker(ctx sdk.Context)

func (Keeper) Borrow

func (k Keeper) Borrow(ctx sdk.Context, collateralAmount math.Int, custodyAmount math.Int, mtp *types.MTP, ammPool *ammtypes.Pool, pool *types.Pool, eta sdk.Dec, baseCurrency string, isBroker bool) error

func (Keeper) BorrowInterestRateComputation

func (k Keeper) BorrowInterestRateComputation(ctx sdk.Context, pool types.Pool) (sdk.Dec, error)

func (Keeper) BorrowInterestRateComputationByPosition

func (k Keeper) BorrowInterestRateComputationByPosition(ctx sdk.Context, pool types.Pool, ammPool ammtypes.Pool, position types.Position) (sdk.Dec, error)

func (Keeper) CalcMTPBorrowInterestLiabilities

func (k Keeper) CalcMTPBorrowInterestLiabilities(ctx sdk.Context, mtp *types.MTP, borrowInterestRate sdk.Dec, epochPosition, epochLength int64, ammPool ammtypes.Pool, baseCurrency string) (math.Int, error)

func (Keeper) CalcMTPConsolidateCollateral

func (k Keeper) CalcMTPConsolidateCollateral(ctx sdk.Context, mtp *types.MTP, baseCurrency string) error

func (Keeper) CalcMTPTakeProfitBorrowRate

func (k Keeper) CalcMTPTakeProfitBorrowRate(ctx sdk.Context, mtp *types.MTP) (sdk.Dec, error)

func (Keeper) CalcMTPTakeProfitLiability

func (k Keeper) CalcMTPTakeProfitLiability(ctx sdk.Context, mtp *types.MTP, baseCurrency string) (math.Int, error)

func (Keeper) CalcMinCollateral

func (k Keeper) CalcMinCollateral(ctx sdk.Context, leverage sdk.Dec, price sdk.Dec, decimals uint64) (math.Int, error)

CalcMinCollateral calculates the minimum collateral required to open a position

func (Keeper) CalculatePoolHealth

func (k Keeper) CalculatePoolHealth(ctx sdk.Context, pool *types.Pool) sdk.Dec

func (Keeper) CalculatePoolHealthByPosition

func (k Keeper) CalculatePoolHealthByPosition(ctx sdk.Context, pool *types.Pool, ammPool ammtypes.Pool, position types.Position) sdk.Dec

func (Keeper) CheckIfWhitelisted

func (k Keeper) CheckIfWhitelisted(ctx sdk.Context, address string) bool

func (Keeper) CheckMaxOpenPositions

func (k Keeper) CheckMaxOpenPositions(ctx sdk.Context) error

func (Keeper) CheckMinLiabilities

func (k Keeper) CheckMinLiabilities(ctx sdk.Context, collateralAmount sdk.Coin, eta sdk.Dec, ammPool ammtypes.Pool, custodyAsset string, baseCurrency string) error

func (Keeper) CheckPoolHealth

func (k Keeper) CheckPoolHealth(ctx sdk.Context, poolId uint64) error

func (Keeper) CheckSameAssetPosition

func (k Keeper) CheckSameAssetPosition(ctx sdk.Context, msg *types.MsgOpen) *types.MTP

func (Keeper) CheckUserAuthorization

func (k Keeper) CheckUserAuthorization(ctx sdk.Context, msg *types.MsgOpen) error

func (Keeper) Close

func (k Keeper) Close(ctx sdk.Context, msg *types.MsgClose) (*types.MsgCloseResponse, error)

func (Keeper) CloseLong

func (k Keeper) CloseLong(ctx sdk.Context, msg *types.MsgClose, baseCurrency string) (*types.MTP, math.Int, error)

func (Keeper) CloseShort

func (k Keeper) CloseShort(ctx sdk.Context, msg *types.MsgClose, baseCurrency string) (*types.MTP, math.Int, error)

func (Keeper) DestroyMTP

func (k Keeper) DestroyMTP(ctx sdk.Context, mtpAddress string, id uint64) error

func (Keeper) DewhitelistAddress

func (k Keeper) DewhitelistAddress(ctx sdk.Context, address string)

func (Keeper) EmitCloseEvent added in v0.29.3

func (k Keeper) EmitCloseEvent(ctx sdk.Context, mtp *types.MTP, repayAmount math.Int)

func (Keeper) EmitForceClose

func (k Keeper) EmitForceClose(ctx sdk.Context, mtp *types.MTP, repayAmount math.Int, closer string)

func (Keeper) EmitFundPayment

func (k Keeper) EmitFundPayment(ctx sdk.Context, mtp *types.MTP, takeAmount math.Int, takeAsset string, paymentType string)

func (Keeper) EmitFundingFeePayment

func (k Keeper) EmitFundingFeePayment(ctx sdk.Context, mtp *types.MTP, takeAmount math.Int, takeAsset string, paymentType string)

func (Keeper) EmitOpenEvent

func (k Keeper) EmitOpenEvent(ctx sdk.Context, mtp *types.MTP)

func (Keeper) EstimateAndRepay

func (k Keeper) EstimateAndRepay(ctx sdk.Context, mtp types.MTP, pool types.Pool, ammPool ammtypes.Pool, amount math.Int, baseCurrency string) (math.Int, error)

func (Keeper) EstimateSwap

func (k Keeper) EstimateSwap(ctx sdk.Context, tokenInAmount sdk.Coin, tokenOutDenom string, ammPool ammtypes.Pool) (math.Int, error)

Swap estimation using amm CalcOutAmtGivenIn function

func (Keeper) EstimateSwapGivenOut

func (k Keeper) EstimateSwapGivenOut(ctx sdk.Context, tokenOutAmount sdk.Coin, tokenInDenom string, ammPool ammtypes.Pool) (math.Int, error)

Swap estimation using amm CalcInAmtGivenOut function

func (Keeper) ForceCloseLong

func (k Keeper) ForceCloseLong(ctx sdk.Context, mtp *types.MTP, pool *types.Pool, takeFundPayment bool, baseCurrency string) (math.Int, error)

func (Keeper) ForceCloseShort

func (k Keeper) ForceCloseShort(ctx sdk.Context, mtp *types.MTP, pool *types.Pool, takeFundPayment bool, baseCurrency string) (math.Int, error)

func (Keeper) GetAllMTPs

func (k Keeper) GetAllMTPs(ctx sdk.Context) []types.MTP

func (Keeper) GetAllPools

func (k Keeper) GetAllPools(ctx sdk.Context) (list []types.Pool)

GetAllPool returns all pool

func (Keeper) GetAllWhitelistedAddress

func (k Keeper) GetAllWhitelistedAddress(ctx sdk.Context) []string

func (Keeper) GetAmmPool

func (k Keeper) GetAmmPool(ctx sdk.Context, poolId uint64, tradingAsset string) (ammtypes.Pool, error)

func (Keeper) GetBestPool

func (k Keeper) GetBestPool(ctx sdk.Context, collateralAsset string, tradingAsset string) (uint64, error)

func (Keeper) GetBorrowInterestRateDecrease

func (k Keeper) GetBorrowInterestRateDecrease(ctx sdk.Context) sdk.Dec

func (Keeper) GetBorrowInterestRateIncrease

func (k Keeper) GetBorrowInterestRateIncrease(ctx sdk.Context) sdk.Dec

func (Keeper) GetBorrowInterestRateMax

func (k Keeper) GetBorrowInterestRateMax(ctx sdk.Context) sdk.Dec

func (Keeper) GetBorrowInterestRateMin

func (k Keeper) GetBorrowInterestRateMin(ctx sdk.Context) sdk.Dec

func (Keeper) GetEnabledPools

func (k Keeper) GetEnabledPools(ctx sdk.Context) []uint64

func (Keeper) GetEpochLength

func (k Keeper) GetEpochLength(ctx sdk.Context) int64

func (Keeper) GetEpochPosition

func (k Keeper) GetEpochPosition(ctx sdk.Context, epochLength int64) int64

get position of current block in epoch

func (Keeper) GetForceCloseFundAddress

func (k Keeper) GetForceCloseFundAddress(ctx sdk.Context) sdk.AccAddress

func (Keeper) GetForceCloseFundPercentage

func (k Keeper) GetForceCloseFundPercentage(ctx sdk.Context) sdk.Dec

func (Keeper) GetFundingFeeBaseRate

func (k Keeper) GetFundingFeeBaseRate(ctx sdk.Context) sdk.Dec

func (Keeper) GetFundingFeeCollectionAddress

func (k Keeper) GetFundingFeeCollectionAddress(ctx sdk.Context) sdk.AccAddress

func (Keeper) GetFundingFeeMaxRate

func (k Keeper) GetFundingFeeMaxRate(ctx sdk.Context) sdk.Dec

func (Keeper) GetFundingFeeMinRate

func (k Keeper) GetFundingFeeMinRate(ctx sdk.Context) sdk.Dec

func (Keeper) GetHealthGainFactor

func (k Keeper) GetHealthGainFactor(ctx sdk.Context) sdk.Dec

func (Keeper) GetIncrementalBorrowInterestPaymentEnabled

func (k Keeper) GetIncrementalBorrowInterestPaymentEnabled(ctx sdk.Context) bool

func (Keeper) GetIncrementalBorrowInterestPaymentFundAddress

func (k Keeper) GetIncrementalBorrowInterestPaymentFundAddress(ctx sdk.Context) sdk.AccAddress

func (Keeper) GetIncrementalBorrowInterestPaymentFundPercentage

func (k Keeper) GetIncrementalBorrowInterestPaymentFundPercentage(ctx sdk.Context) sdk.Dec

func (Keeper) GetMTP

func (k Keeper) GetMTP(ctx sdk.Context, mtpAddress string, id uint64) (types.MTP, error)

func (Keeper) GetMTPCount

func (k Keeper) GetMTPCount(ctx sdk.Context) uint64

func (Keeper) GetMTPIterator

func (k Keeper) GetMTPIterator(ctx sdk.Context) sdk.Iterator

func (Keeper) GetMTPs

func (k Keeper) GetMTPs(ctx sdk.Context, pagination *query.PageRequest) ([]*types.MTP, *query.PageResponse, error)

func (Keeper) GetMTPsForAddress

func (k Keeper) GetMTPsForAddress(ctx sdk.Context, mtpAddress sdk.Address, pagination *query.PageRequest) ([]*types.MTP, *query.PageResponse, error)

func (Keeper) GetMTPsForPool

func (k Keeper) GetMTPsForPool(ctx sdk.Context, ammPoolId uint64, pagination *query.PageRequest) ([]*types.MTP, *query.PageResponse, error)

func (Keeper) GetMaxLeverageParam

func (k Keeper) GetMaxLeverageParam(ctx sdk.Context) sdk.Dec

func (Keeper) GetMaxOpenPositions

func (k Keeper) GetMaxOpenPositions(ctx sdk.Context) uint64

func (Keeper) GetOpenMTPCount

func (k Keeper) GetOpenMTPCount(ctx sdk.Context) uint64

func (Keeper) GetParams

func (k Keeper) GetParams(ctx sdk.Context) (params types.Params)

GetParams get all parameters as types.Params

func (Keeper) GetPool

func (k Keeper) GetPool(ctx sdk.Context, poolId uint64) (val types.Pool, found bool)

GetPool returns a pool from its index

func (Keeper) GetPoolOpenThreshold

func (k Keeper) GetPoolOpenThreshold(ctx sdk.Context) sdk.Dec

func (Keeper) GetPositions

func (k Keeper) GetPositions(goCtx context.Context, req *types.PositionsRequest) (*types.PositionsResponse, error)

func (Keeper) GetPositionsByPool

func (k Keeper) GetPositionsByPool(goCtx context.Context, req *types.PositionsByPoolRequest) (*types.PositionsByPoolResponse, error)

func (Keeper) GetSafetyFactor

func (k Keeper) GetSafetyFactor(ctx sdk.Context) sdk.Dec

func (Keeper) GetStatus

func (k Keeper) GetStatus(goCtx context.Context, req *types.StatusRequest) (*types.StatusResponse, error)

func (Keeper) GetSwapFee

func (k Keeper) GetSwapFee(ctx sdk.Context) sdk.Dec

func (Keeper) GetTakeProfitBorrowInterestRateMin

func (k Keeper) GetTakeProfitBorrowInterestRateMin(ctx sdk.Context) sdk.Dec

func (Keeper) GetWhitelist

func (k Keeper) GetWhitelist(goCtx context.Context, req *types.WhitelistRequest) (*types.WhitelistResponse, error)

func (Keeper) GetWhitelistAddressIterator

func (k Keeper) GetWhitelistAddressIterator(ctx sdk.Context) sdk.Iterator

func (Keeper) GetWhitelistedAddress

func (k Keeper) GetWhitelistedAddress(ctx sdk.Context, pagination *query.PageRequest) ([]string, *query.PageResponse, error)

func (Keeper) HandleBorrowInterest

func (k Keeper) HandleBorrowInterest(ctx sdk.Context, mtp *types.MTP, pool *types.Pool, ammPool ammtypes.Pool) error

func (Keeper) HandleBorrowInterestPayment

func (k Keeper) HandleBorrowInterestPayment(ctx sdk.Context, borrowInterestPayment math.Int, mtp *types.MTP, pool *types.Pool, ammPool ammtypes.Pool, baseCurrency string) math.Int

func (Keeper) HandleFundingFeeCollection

func (k Keeper) HandleFundingFeeCollection(ctx sdk.Context, mtp *types.MTP, pool *types.Pool, ammPool ammtypes.Pool, baseCurrency string) error

HandleFundingFeeCollection handles funding fee collection

func (Keeper) HandleFundingFeeDistribution

func (k Keeper) HandleFundingFeeDistribution(ctx sdk.Context, mtps []*types.MTP, pool *types.Pool, ammPool ammtypes.Pool, baseCurrency string) error

HandleFundingFeeDistribution handles funding fee distribution

func (Keeper) Hooks

func (k Keeper) Hooks() Hooks

Return the wrapper struct

func (Keeper) IncrementalBorrowInterestPayment

func (k Keeper) IncrementalBorrowInterestPayment(ctx sdk.Context, borrowInterestPayment math.Int, mtp *types.MTP, pool *types.Pool, ammPool ammtypes.Pool, baseCurrency string) (math.Int, error)

func (Keeper) InvariantCheck

func (k Keeper) InvariantCheck(ctx sdk.Context) error

Check if amm pool balance in bank module is correct

func (Keeper) IsPoolClosed

func (k Keeper) IsPoolClosed(ctx sdk.Context, poolId uint64) bool

func (Keeper) IsPoolEnabled

func (k Keeper) IsPoolEnabled(ctx sdk.Context, poolId uint64) bool

func (Keeper) IsWhitelisted

func (Keeper) IsWhitelistingEnabled

func (k Keeper) IsWhitelistingEnabled(ctx sdk.Context) bool

func (Keeper) Logger

func (k Keeper) Logger(ctx sdk.Context) log.Logger

func (Keeper) MTP

func (k Keeper) MTP(goCtx context.Context, req *types.MTPRequest) (*types.MTPResponse, error)

func (Keeper) Open

func (k Keeper) Open(ctx sdk.Context, msg *types.MsgOpen, isBroker bool) (*types.MsgOpenResponse, error)

func (Keeper) OpenConsolidate

func (k Keeper) OpenConsolidate(ctx sdk.Context, existingMtp *types.MTP, newMtp *types.MTP, msg *types.MsgOpen, baseCurrency string) (*types.MsgOpenResponse, error)

func (Keeper) OpenConsolidateLong

func (k Keeper) OpenConsolidateLong(ctx sdk.Context, poolId uint64, existingMtp *types.MTP, newMtp *types.MTP, msg *types.MsgOpen, baseCurrency string) (*types.MTP, error)

func (Keeper) OpenConsolidateShort

func (k Keeper) OpenConsolidateShort(ctx sdk.Context, poolId uint64, existingMtp *types.MTP, newMtp *types.MTP, msg *types.MsgOpen, baseCurrency string) (*types.MTP, error)

func (Keeper) OpenLong

func (k Keeper) OpenLong(ctx sdk.Context, poolId uint64, msg *types.MsgOpen, baseCurrency string, isBroker bool) (*types.MTP, error)

func (Keeper) OpenShort

func (k Keeper) OpenShort(ctx sdk.Context, poolId uint64, msg *types.MsgOpen, baseCurrency string, isBroker bool) (*types.MTP, error)

func (Keeper) Params

func (k Keeper) Params(goCtx context.Context, req *types.ParamsRequest) (*types.ParamsResponse, error)

func (Keeper) Pool

func (Keeper) Pools

func (Keeper) PreparePools

func (k Keeper) PreparePools(ctx sdk.Context, collateralAsset, tradingAsset string) (poolId uint64, ammPool ammtypes.Pool, pool types.Pool, err error)

PreparePools creates accounted pools

func (Keeper) ProcessOpenLong

func (k Keeper) ProcessOpenLong(ctx sdk.Context, mtp *types.MTP, leverage sdk.Dec, eta sdk.Dec, collateralAmountDec sdk.Dec, poolId uint64, msg *types.MsgOpen, baseCurrency string, isBroker bool) (*types.MTP, error)

func (Keeper) ProcessOpenShort

func (k Keeper) ProcessOpenShort(ctx sdk.Context, mtp *types.MTP, leverage sdk.Dec, eta sdk.Dec, collateralAmountDec sdk.Dec, poolId uint64, msg *types.MsgOpen, baseCurrency string, isBroker bool) (*types.MTP, error)

func (Keeper) RemovePool

func (k Keeper) RemovePool(ctx sdk.Context, index uint64)

RemovePool removes a pool from the store

func (Keeper) Repay

func (k Keeper) Repay(ctx sdk.Context, mtp *types.MTP, pool *types.Pool, ammPool ammtypes.Pool, repayAmount math.Int, takeFundPayment bool, amount math.Int, baseCurrency string) error

func (Keeper) ResetStore

func (k Keeper) ResetStore(ctx sdk.Context) error

ResetStore resets all keys in the perpetual module store

func (Keeper) SetEnabledPools

func (k Keeper) SetEnabledPools(ctx sdk.Context, pools []uint64)

func (*Keeper) SetHooks

func (k *Keeper) SetHooks(gh types.PerpetualHooks) *Keeper

Set the perpetual hooks.

func (Keeper) SetMTP

func (k Keeper) SetMTP(ctx sdk.Context, mtp *types.MTP) error

func (Keeper) SetMTPCount

func (k Keeper) SetMTPCount(ctx sdk.Context, count uint64)

Set MTP count

func (Keeper) SetOpenMTPCount

func (k Keeper) SetOpenMTPCount(ctx sdk.Context, count uint64)

Set Open MTP count

func (Keeper) SetParams

func (k Keeper) SetParams(ctx sdk.Context, params *types.Params) error

SetParams set the params

func (Keeper) SetPool

func (k Keeper) SetPool(ctx sdk.Context, pool types.Pool)

SetPool set a specific pool in the store from its index

func (Keeper) TakeFundPayment

func (k Keeper) TakeFundPayment(ctx sdk.Context, returnAmount math.Int, returnAsset string, takePercentage sdk.Dec, fundAddr sdk.AccAddress, ammPool *ammtypes.Pool) (math.Int, error)

func (Keeper) TakeInCustody

func (k Keeper) TakeInCustody(ctx sdk.Context, mtp types.MTP, pool *types.Pool) error

func (Keeper) TakeOutCustody

func (k Keeper) TakeOutCustody(ctx sdk.Context, mtp types.MTP, pool *types.Pool, amount math.Int) error

func (Keeper) UpdateFundingRate

func (k Keeper) UpdateFundingRate(ctx sdk.Context, pool *types.Pool) error

UpdateFundingRate updates the funding rate of a pool

func (Keeper) UpdateMTPHealth

func (k Keeper) UpdateMTPHealth(ctx sdk.Context, mtp types.MTP, ammPool ammtypes.Pool, baseCurrency string) (sdk.Dec, error)

func (Keeper) UpdateOpenPrice added in v0.29.17

func (k Keeper) UpdateOpenPrice(ctx sdk.Context, mtp *types.MTP, ammPool ammtypes.Pool, baseCurrency string) error

func (Keeper) UpdatePoolHealth

func (k Keeper) UpdatePoolHealth(ctx sdk.Context, pool *types.Pool) error

func (Keeper) WhitelistAddress

func (k Keeper) WhitelistAddress(ctx sdk.Context, address string)

Source Files

Jump to

Keyboard shortcuts

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