Versions in this module Expand all Collapse all v28 v28.0.0 Dec 5, 2024 Changes in this version + func EmitBackrunEvent(ctx sdk.Context, pool SwapToBackrun, inputCoin sdk.Coin, ...) + func NewMsgServer(keeper Keeper) types.MsgServer + type EpochHooks struct + func (EpochHooks) GetModuleName() string + func (h EpochHooks) AfterEpochEnd(ctx sdk.Context, epochIdentifier string, epochNumber int64) error + func (h EpochHooks) BeforeEpochStart(ctx sdk.Context, epochIdentifier string, epochNumber int64) error + func (h EpochHooks) CalculateAndDistributeProfits(ctx sdk.Context) error + type Hooks struct + func (h Hooks) AfterCFMMPoolCreated(ctx sdk.Context, sender sdk.AccAddress, poolId uint64) + func (h Hooks) AfterCFMMSwap(ctx sdk.Context, sender sdk.AccAddress, poolId uint64, input sdk.Coins, ...) + func (h Hooks) AfterConcentratedPoolCreated(ctx sdk.Context, sender sdk.AccAddress, poolId uint64) + func (h Hooks) AfterConcentratedPoolSwap(ctx sdk.Context, sender sdk.AccAddress, poolId uint64, input sdk.Coins, ...) + func (h Hooks) AfterExitPool(ctx sdk.Context, sender sdk.AccAddress, poolId uint64, ...) + func (h Hooks) AfterInitialPoolPositionCreated(ctx sdk.Context, sender sdk.AccAddress, poolId uint64) + func (h Hooks) AfterJoinPool(ctx sdk.Context, sender sdk.AccAddress, poolId uint64, enterCoins sdk.Coins, ...) + func (h Hooks) AfterLastPoolPositionRemoved(ctx sdk.Context, sender sdk.AccAddress, poolId uint64) + type Keeper struct + func NewKeeper(cdc codec.BinaryCodec, storeKey storetypes.StoreKey, ...) Keeper + func (k Keeper) AddSwapsToSwapsToBackrun(ctx sdk.Context, swaps []types.Trade) error + func (k Keeper) AfterPoolCreatedWithCoins(ctx sdk.Context, poolId uint64) + func (k Keeper) AnteHandleCheck(ctx sdk.Context) error + func (k Keeper) BuildHighestLiquidityRoute(ctx sdk.Context, swapDenom types.BaseDenom, tokenIn, tokenOut string, ...) (RouteMetaData, error) + func (k Keeper) BuildHighestLiquidityRoutes(ctx sdk.Context, tokenIn, tokenOut string, poolId uint64) ([]RouteMetaData, error) + func (k Keeper) BuildHotRoute(ctx sdk.Context, route types.Route, poolId uint64) (RouteMetaData, error) + func (k Keeper) BuildHotRoutes(ctx sdk.Context, tokenIn, tokenOut string, poolId uint64) ([]RouteMetaData, error) + func (k Keeper) BuildRoutes(ctx sdk.Context, tokenIn, tokenOut string, poolId uint64) []RouteMetaData + func (k Keeper) BuildTwoPoolRoute(ctx sdk.Context, baseDenom types.BaseDenom, tokenInDenom, tokenOutDenom string, ...) (RouteMetaData, error) + func (k Keeper) CalculateRoutePoolPoints(ctx sdk.Context, route poolmanagertypes.SwapAmountInRoutes) (uint64, error) + func (k Keeper) CalculateUpperBoundForSearch(ctx sdk.Context, route RouteMetaData, inputDenom string) (osmomath.Int, error) + func (k Keeper) CompareAndStorePool(ctx sdk.Context, poolId uint64, baseDenom, otherDenom string) + func (k Keeper) ConvertProfits(ctx sdk.Context, inputCoin sdk.Coin, profit osmomath.Int) (osmomath.Int, error) + func (k Keeper) CurrentBaseDenomProfits(ctx sdk.Context) (sdk.Coins, error) + func (k Keeper) DeleteAllEntriesForKeyPrefix(ctx sdk.Context, keyPrefix []byte) + func (k Keeper) DeleteAllPoolsForBaseDenom(ctx sdk.Context, baseDenom string) + func (k Keeper) DeleteAllTokenPairArbRoutes(ctx sdk.Context) + func (k Keeper) DeleteDeveloperFees(ctx sdk.Context, denom string) + func (k Keeper) DeleteSwapsToBackrun(ctx sdk.Context) + func (k Keeper) DeprecatedDeleteBaseDenoms(ctx sdk.Context) + func (k Keeper) DeprecatedGetAllBaseDenoms(ctx sdk.Context) ([]types.BaseDenom, error) + func (k Keeper) DeprecatedSetBaseDenoms(ctx sdk.Context, baseDenoms []types.BaseDenom) error + func (k Keeper) DistributeProfit(ctx sdk.Context, arbProfits sdk.Coins) error + func (k Keeper) EpochHooks() epochstypes.EpochHooks + func (k Keeper) EstimateMultihopProfit(ctx sdk.Context, inputDenom string, amount osmomath.Int, ...) (sdk.Coin, osmomath.Int, error) + func (k Keeper) ExecuteTrade(ctx sdk.Context, route poolmanagertypes.SwapAmountInRoutes, inputCoin sdk.Coin, ...) error + func (k Keeper) ExportGenesis(ctx sdk.Context) *types.GenesisState + func (k Keeper) ExtendSearchRangeIfNeeded(ctx sdk.Context, route RouteMetaData, inputDenom string, ...) (osmomath.Int, osmomath.Int, error) + func (k Keeper) ExtractSwappedPools(ctx sdk.Context) []SwapToBackrun + func (k Keeper) FindMaxProfitForRoute(ctx sdk.Context, route RouteMetaData, ...) (sdk.Coin, osmomath.Int, error) + func (k Keeper) GetAdminAccount(ctx sdk.Context) sdk.AccAddress + func (k Keeper) GetAllBaseDenoms(ctx sdk.Context) ([]types.BaseDenom, error) + func (k Keeper) GetAllDeveloperFees(ctx sdk.Context) ([]sdk.Coin, error) + func (k Keeper) GetAllProfits(ctx sdk.Context) []sdk.Coin + func (k Keeper) GetAllProfitsByRoute(ctx sdk.Context, route []uint64) []sdk.Coin + func (k Keeper) GetAllProtocolRevenue(ctx sdk.Context) types.AllProtocolRevenue + func (k Keeper) GetAllRoutes(ctx sdk.Context) ([][]uint64, error) + func (k Keeper) GetAllTokenPairArbRoutes(ctx sdk.Context) ([]types.TokenPairArbRoutes, error) + func (k Keeper) GetComparablePoolLiquidity(ctx sdk.Context, poolId uint64) (comparableLiquidity osmomath.Int, err error) + func (k Keeper) GetCyclicArbProfitTrackerStartHeight(ctx sdk.Context) int64 + func (k Keeper) GetCyclicArbProfitTrackerValue(ctx sdk.Context) (currentCyclicArbProfits sdk.Coins) + func (k Keeper) GetDaysSinceModuleGenesis(ctx sdk.Context) (uint64, error) + func (k Keeper) GetDeveloperAccount(ctx sdk.Context) (sdk.AccAddress, error) + func (k Keeper) GetDeveloperFees(ctx sdk.Context, denom string) (sdk.Coin, error) + func (k Keeper) GetInfoByPoolType(ctx sdk.Context) types.InfoByPoolType + func (k Keeper) GetLatestBlockHeight(ctx sdk.Context) (uint64, error) + func (k Keeper) GetMaxPointsPerBlock(ctx sdk.Context) (uint64, error) + func (k Keeper) GetMaxPointsPerTx(ctx sdk.Context) (uint64, error) + func (k Keeper) GetNumberOfTrades(ctx sdk.Context) (osmomath.Int, error) + func (k Keeper) GetParams(ctx sdk.Context) (params types.Params) + func (k Keeper) GetPointCountForBlock(ctx sdk.Context) (uint64, error) + func (k Keeper) GetPoolForDenomPair(ctx sdk.Context, baseDenom, denomToMatch string) (uint64, error) + func (k Keeper) GetPoolForDenomPairNoOrder(ctx sdk.Context, tokenA, tokenB string) (uint64, error) + func (k Keeper) GetProfitsByDenom(ctx sdk.Context, denom string) (sdk.Coin, error) + func (k Keeper) GetProfitsByRoute(ctx sdk.Context, route []uint64, denom string) (sdk.Coin, error) + func (k Keeper) GetProtoRevEnabled(ctx sdk.Context) bool + func (k Keeper) GetRemainingPoolPoints(ctx sdk.Context) (uint64, uint64, error) + func (k Keeper) GetSwapsToBackrun(ctx sdk.Context) (types.Route, error) + func (k Keeper) GetTokenPairArbRoutes(ctx sdk.Context, tokenA, tokenB string) (types.TokenPairArbRoutes, error) + func (k Keeper) GetTradesByRoute(ctx sdk.Context, route []uint64) (osmomath.Int, error) + func (k Keeper) Hooks() Hooks + func (k Keeper) IncrementNumberOfTrades(ctx sdk.Context) error + func (k Keeper) IncrementPointCountForBlock(ctx sdk.Context, amount uint64) error + func (k Keeper) IncrementTradesByRoute(ctx sdk.Context, route []uint64) error + func (k Keeper) InitGenesis(ctx sdk.Context, genState types.GenesisState) + func (k Keeper) IsValidPool(ctx sdk.Context, pool poolmanagertypes.PoolI) error + func (k Keeper) IterateRoutes(ctx sdk.Context, routes []RouteMetaData, ...) (sdk.Coin, osmomath.Int, poolmanagertypes.SwapAmountInRoutes) + func (k Keeper) Logger(ctx sdk.Context) log.Logger + func (k Keeper) ProtoRevTrade(ctx sdk.Context, swappedPools []SwapToBackrun) (err error) + func (k Keeper) SetAdminAccount(ctx sdk.Context, adminAccount sdk.AccAddress) + func (k Keeper) SetBaseDenoms(ctx sdk.Context, baseDenoms []types.BaseDenom) error + func (k Keeper) SetCyclicArbProfitTrackerStartHeight(ctx sdk.Context, startHeight int64) + func (k Keeper) SetCyclicArbProfitTrackerValue(ctx sdk.Context, cyclicArbProfits sdk.Coins) + func (k Keeper) SetDaysSinceModuleGenesis(ctx sdk.Context, daysSinceGenesis uint64) + func (k Keeper) SetDeveloperAccount(ctx sdk.Context, developerAccount sdk.AccAddress) + func (k Keeper) SetDeveloperFees(ctx sdk.Context, developerFees sdk.Coin) error + func (k Keeper) SetInfoByPoolType(ctx sdk.Context, poolWeights types.InfoByPoolType) + func (k Keeper) SetLatestBlockHeight(ctx sdk.Context, blockHeight uint64) + func (k Keeper) SetMaxPointsPerBlock(ctx sdk.Context, maxPoints uint64) error + func (k Keeper) SetMaxPointsPerTx(ctx sdk.Context, maxPoints uint64) error + func (k Keeper) SetParam(ctx sdk.Context, key []byte, value interface{}) + func (k Keeper) SetParams(ctx sdk.Context, params types.Params) + func (k Keeper) SetPointCountForBlock(ctx sdk.Context, pointCount uint64) + func (k Keeper) SetPoolForDenomPair(ctx sdk.Context, baseDenom, denomToMatch string, poolId uint64) + func (k Keeper) SetProtoRevEnabled(ctx sdk.Context, enabled bool) + func (k Keeper) SetSwapsToBackrun(ctx sdk.Context, swapsToBackrun types.Route) error + func (k Keeper) SetTokenPairArbRoutes(ctx sdk.Context, tokenA, tokenB string, tokenPair types.TokenPairArbRoutes) error + func (k Keeper) StoreJoinExitPoolSwaps(ctx sdk.Context, sender sdk.AccAddress, poolId uint64, denom string, ...) + func (k Keeper) StoreSwap(ctx sdk.Context, poolId uint64, tokenIn, tokenOut string) + func (k Keeper) UpdateHighestLiquidityPools(ctx sdk.Context, baseDenomPools map[string]map[string]LiquidityPoolStruct) error + func (k Keeper) UpdatePools(ctx sdk.Context) error + func (k Keeper) UpdateProfitsByDenom(ctx sdk.Context, denom string, tradeProfit osmomath.Int) error + func (k Keeper) UpdateProfitsByRoute(ctx sdk.Context, route []uint64, denom string, profit osmomath.Int) error + func (k Keeper) UpdateSearchRangeIfNeeded(ctx sdk.Context, route RouteMetaData, inputDenom string, ...) (osmomath.Int, osmomath.Int, error) + func (k Keeper) UpdateStatistics(ctx sdk.Context, route poolmanagertypes.SwapAmountInRoutes, denom string, ...) error + type LiquidityPoolStruct struct + Liquidity osmomath.Int + PoolId uint64 + type MsgServer struct + func (m MsgServer) AdminCheck(ctx sdk.Context, admin string) error + func (m MsgServer) SetBaseDenoms(c context.Context, msg *types.MsgSetBaseDenoms) (*types.MsgSetBaseDenomsResponse, error) + func (m MsgServer) SetDeveloperAccount(c context.Context, msg *types.MsgSetDeveloperAccount) (*types.MsgSetDeveloperAccountResponse, error) + func (m MsgServer) SetHotRoutes(c context.Context, msg *types.MsgSetHotRoutes) (*types.MsgSetHotRoutesResponse, error) + func (m MsgServer) SetInfoByPoolType(c context.Context, msg *types.MsgSetInfoByPoolType) (*types.MsgSetInfoByPoolTypeResponse, error) + func (m MsgServer) SetMaxPoolPointsPerBlock(c context.Context, msg *types.MsgSetMaxPoolPointsPerBlock) (*types.MsgSetMaxPoolPointsPerBlockResponse, error) + func (m MsgServer) SetMaxPoolPointsPerTx(c context.Context, msg *types.MsgSetMaxPoolPointsPerTx) (*types.MsgSetMaxPoolPointsPerTxResponse, error) + type ProtoRevDecorator struct + ProtoRevKeeper Keeper + func NewProtoRevDecorator(protoRevDecorator Keeper) ProtoRevDecorator + func (protoRevDec ProtoRevDecorator) PostHandle(ctx sdk.Context, tx sdk.Tx, simulate, success bool, next sdk.PostHandler) (sdk.Context, error) + type Querier struct + func NewQuerier(k Keeper) Querier + func (q Querier) GetAllProtocolRevenue(c context.Context, req *types.QueryGetAllProtocolRevenueRequest) (*types.QueryGetAllProtocolRevenueResponse, error) + func (q Querier) GetProtoRevAdminAccount(c context.Context, req *types.QueryGetProtoRevAdminAccountRequest) (*types.QueryGetProtoRevAdminAccountResponse, error) + func (q Querier) GetProtoRevAllProfits(c context.Context, req *types.QueryGetProtoRevAllProfitsRequest) (*types.QueryGetProtoRevAllProfitsResponse, error) + func (q Querier) GetProtoRevAllRouteStatistics(c context.Context, req *types.QueryGetProtoRevAllRouteStatisticsRequest) (*types.QueryGetProtoRevAllRouteStatisticsResponse, error) + func (q Querier) GetProtoRevBaseDenoms(c context.Context, req *types.QueryGetProtoRevBaseDenomsRequest) (*types.QueryGetProtoRevBaseDenomsResponse, error) + func (q Querier) GetProtoRevDeveloperAccount(c context.Context, req *types.QueryGetProtoRevDeveloperAccountRequest) (*types.QueryGetProtoRevDeveloperAccountResponse, error) + func (q Querier) GetProtoRevEnabled(c context.Context, req *types.QueryGetProtoRevEnabledRequest) (*types.QueryGetProtoRevEnabledResponse, error) + func (q Querier) GetProtoRevInfoByPoolType(c context.Context, req *types.QueryGetProtoRevInfoByPoolTypeRequest) (*types.QueryGetProtoRevInfoByPoolTypeResponse, error) + func (q Querier) GetProtoRevMaxPoolPointsPerBlock(c context.Context, req *types.QueryGetProtoRevMaxPoolPointsPerBlockRequest) (*types.QueryGetProtoRevMaxPoolPointsPerBlockResponse, error) + func (q Querier) GetProtoRevMaxPoolPointsPerTx(c context.Context, req *types.QueryGetProtoRevMaxPoolPointsPerTxRequest) (*types.QueryGetProtoRevMaxPoolPointsPerTxResponse, error) + func (q Querier) GetProtoRevNumberOfTrades(c context.Context, req *types.QueryGetProtoRevNumberOfTradesRequest) (*types.QueryGetProtoRevNumberOfTradesResponse, error) + func (q Querier) GetProtoRevPool(c context.Context, req *types.QueryGetProtoRevPoolRequest) (*types.QueryGetProtoRevPoolResponse, error) + func (q Querier) GetProtoRevProfitsByDenom(c context.Context, req *types.QueryGetProtoRevProfitsByDenomRequest) (*types.QueryGetProtoRevProfitsByDenomResponse, error) + func (q Querier) GetProtoRevStatisticsByRoute(c context.Context, req *types.QueryGetProtoRevStatisticsByRouteRequest) (*types.QueryGetProtoRevStatisticsByRouteResponse, error) + func (q Querier) GetProtoRevTokenPairArbRoutes(c context.Context, req *types.QueryGetProtoRevTokenPairArbRoutesRequest) (*types.QueryGetProtoRevTokenPairArbRoutesResponse, error) + func (q Querier) Params(c context.Context, req *types.QueryParamsRequest) (*types.QueryParamsResponse, error) + type RouteMetaData struct + PoolPoints uint64 + Route poolmanagertypes.SwapAmountInRoutes + StepSize osmomath.Int + type SwapToBackrun struct + PoolId uint64 + TokenInDenom string + TokenOutDenom string v28.0.0-rc1 Dec 4, 2024 Other modules containing this package github.com/osmosis-labs/osmosis/v15 github.com/osmosis-labs/osmosis/v16 github.com/osmosis-labs/osmosis/v17 github.com/osmosis-labs/osmosis/v19 github.com/osmosis-labs/osmosis/v20 github.com/osmosis-labs/osmosis/v21 github.com/osmosis-labs/osmosis/v22 github.com/osmosis-labs/osmosis/v23 github.com/osmosis-labs/osmosis/v24 github.com/osmosis-labs/osmosis/v25 github.com/osmosis-labs/osmosis/v26 github.com/osmosis-labs/osmosis/v27