The HOT contract implements the two interfaces: ISovereignALM and ISwapFeeModuleMinimal
import { ALMLiquidityQuoteInput, ALMLiquidityQuote } from'../structs/SovereignALMStructs.sol';/**@title Sovereign ALM interface@notice All ALMs bound to a Sovereign Pool must implement it. */interface ISovereignALM {/** @notice Called by the Sovereign pool to request a liquidity quote from the ALM.@param _almLiquidityQuoteInput Contains fundamental data about the swap.@param _externalContext Data received by the pool from the user.@param _verifierData Verification data received by the pool from the verifier module@return almLiquidityQuote Liquidity quote containing tokenIn and tokenOut amounts filled. */functiongetLiquidityQuote(ALMLiquidityQuoteInputmemory_almLiquidityQuoteInput,bytescalldata_externalContext,bytescalldata_verifierData ) externalreturns (ALMLiquidityQuotememory);/**@notice Callback function for `depositLiquidity` .@param _amount0 Amount of token0 being deposited.@param _amount1 Amount of token1 being deposited.@param _data Context data passed by the ALM, while calling `depositLiquidity`. */functiononDepositLiquidityCallback(uint256_amount0,uint256_amount1,bytesmemory_data) external;/**@notice Callback to ALM after swap into liquidity pool.@dev Only callable by pool.@param _isZeroToOne Direction of swap.@param _amountIn Amount of tokenIn in swap.@param _amountOut Amount of tokenOut in swap. */functiononSwapCallback(bool_isZeroToOne,uint256_amountIn,uint256_amountOut) external;}
/**@notice Struct returned by the swapFeeModule during the getSwapFeeInBips call. * feeInBips: The swap fee in bips. * internalContext: Arbitrary bytes context data. */structSwapFeeModuleData {uint256 feeInBips;bytes internalContext;}interface ISwapFeeModuleMinimal {/**@notice Returns the swap fee in bips for both Universal & Sovereign Pools.@param _tokenIn The address of the token that the user wants to swap.@param _tokenOut The address of the token that the user wants to receive.@param _amountIn The amount of tokenIn being swapped.@param _user The address of the user.@param _swapFeeModuleContext Arbitrary bytes data which can be sent to the swap fee module.@return swapFeeModuleData A struct containing the swap fee in bips, and internal context data. */functiongetSwapFeeInBips(address_tokenIn,address_tokenOut,uint256_amountIn,address_user,bytesmemory_swapFeeModuleContext ) externalreturns (SwapFeeModuleDatamemory swapFeeModuleData);}
The HOT does not implement the following method:
ISwapFeeModule.callbackOnSwapEnd Not implemented, since the SOT does not need to perform any post-swap state updates regarding its fee calculation logic.