Fee Manager
Interface
/// @dev The manager contract to control fees.
/// Management functions are omitted.
interface IFeeManager {
function defaultSwapFee(uint16 poolType) external view returns (uint24);
// [Deprecated] The old interface before the dynamic fees update.
//function customSwapFee(address pool) external view returns (uint24);
function feeRecipient() external view returns (address);
// [Deprecated] The old interface before the dynamic fees update.
//function protocolFee(uint16 poolType) external view returns (uint24);
// [Deprecated] The old interface before the dynamic fees update.
//function getSwapFee(address pool) external view returns (uint24 swapFee);
// [Recommended] The new interface after the dynamic fees update.
/// @dev Returns `0` for zero pool fee.
function getSwapFee(
address pool,
address sender,
address tokenIn,
address tokenOut,
bytes calldata data
) external view returns (uint24 fee);
// [Recommended] The new interface after the dynamic fees update.
/// @dev Returns `0` for zero pool fee.
function getProtocolFee(address pool) external view returns (uint24 fee);
// [Recommended] The new interface after the dynamic fees update.
function getFeeRecipient() external view returns (address recipient);
// [Recommended] The new interface after the dynamic fees update.
/// @dev Returns `type(uint24).max` for zero pool fee.
function poolSwapFee(address pool) external view returns (uint24);
// [Recommended] The new interface after the dynamic fees update.
/// @dev Returns `0` for zero pool fee.
function defaultProtocolFee(uint16 poolType) external view returns (uint24);
// [Recommended] The new interface after the dynamic fees update.
/// @dev Returns `type(uint24).max` for zero pool fee.
function poolProtocolFee(address pool) external view returns (uint24);
}
Last updated