loom_defi_abi/uniswap2/
router.rs

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
use alloy_sol_macro::sol;

sol! {

    #[sol(abi=true,rpc)]
    #[derive(Debug, PartialEq, Eq)]
    interface IUniswapV2Router {
        function getAmountOut(uint amountIn, uint reserveIn, uint reserveOut)
            public
            pure
            virtual
            override
            returns (uint amountOut);

        function getAmountIn(uint amountOut, uint reserveIn, uint reserveOut)
            public
            pure
            virtual
            override
            returns (uint amountIn);
    }
}