github.com/status-im/status-go@v1.1.0/contracts/uniswapV3/interfaces/IERC20Minimal.sol (about) 1 // SPDX-License-Identifier: GPL-2.0-or-later 2 pragma solidity >=0.5.0; 3 4 /// @title Minimal ERC20 interface for Uniswap 5 /// @notice Contains a subset of the full ERC20 interface that is used in Uniswap V3 6 interface IERC20Minimal { 7 /// @notice Returns the balance of a token 8 /// @param account The account for which to look up the number of tokens it has, i.e. its balance 9 /// @return The number of tokens held by the account 10 function balanceOf(address account) external view returns (uint256); 11 12 /// @notice Transfers the amount of token from the `msg.sender` to the recipient 13 /// @param recipient The account that will receive the amount transferred 14 /// @param amount The number of tokens to send from the sender to the recipient 15 /// @return Returns true for a successful transfer, false for an unsuccessful transfer 16 function transfer(address recipient, uint256 amount) external returns (bool); 17 18 /// @notice Returns the current allowance given to a spender by an owner 19 /// @param owner The account of the token owner 20 /// @param spender The account of the token spender 21 /// @return The current allowance granted by `owner` to `spender` 22 function allowance(address owner, address spender) external view returns (uint256); 23 24 /// @notice Sets the allowance of a spender from the `msg.sender` to the value `amount` 25 /// @param spender The account which will be allowed to spend a given amount of the owners tokens 26 /// @param amount The amount of tokens allowed to be used by `spender` 27 /// @return Returns true for a successful approval, false for unsuccessful 28 function approve(address spender, uint256 amount) external returns (bool); 29 30 /// @notice Transfers `amount` tokens from `sender` to `recipient` up to the allowance given to the `msg.sender` 31 /// @param sender The account from which the transfer will be initiated 32 /// @param recipient The recipient of the transfer 33 /// @param amount The amount of the transfer 34 /// @return Returns true for a successful transfer, false for unsuccessful 35 function transferFrom( 36 address sender, 37 address recipient, 38 uint256 amount 39 ) external returns (bool); 40 41 /// @notice Event emitted when tokens are transferred from one address to another, either via `#transfer` or `#transferFrom`. 42 /// @param from The account from which the tokens were sent, i.e. the balance decreased 43 /// @param to The account to which the tokens were sent, i.e. the balance increased 44 /// @param value The amount of tokens that were transferred 45 event Transfer(address indexed from, address indexed to, uint256 value); 46 47 /// @notice Event emitted when the approval amount for the spender of a given owner's tokens changes. 48 /// @param owner The account that approved spending of its tokens 49 /// @param spender The account for which the spending allowance was modified 50 /// @param value The new allowance from the owner to the spender 51 event Approval(address indexed owner, address indexed spender, uint256 value); 52 }