IERC20
Author: M^0 Labs
The interface as defined by EIP-20: https://eips.ethereum.org/EIPS/eip-20
Functions
approve
Allows a calling account to approve spender
to spend up to amount
of its token balance.
MUST emit an Approval
event.
Parameters
spender
address
The address of the account being allowed to spend up to the allowed amount.
amount
uint256
The amount of the allowance being approved.
Returns
<none>
bool
Whether or not the approval was successful.
transfer
Allows a calling account to transfer amount
tokens to recipient
.
Parameters
recipient
address
The address of the recipient who's token balance will be incremented.
amount
uint256
The amount of tokens being transferred.
Returns
<none>
bool
Whether or not the transfer was successful.
transferFrom
Allows a calling account to transfer amount
tokens from sender
, with allowance, to a recipient
.
Parameters
sender
address
The address of the sender who's token balance will be decremented.
recipient
address
The address of the recipient who's token balance will be incremented.
amount
uint256
The amount of tokens being transferred.
Returns
<none>
bool
Whether or not the transfer was successful.
allowance
Returns the allowance spender
is allowed to spend on behalf of account
.
Parameters
account
address
The address of the account who's token balance spender
is allowed to spend.
spender
address
The address of an account allowed to spend on behalf of account
.
Returns
<none>
uint256
The amount spender
can spend on behalf of account
.
balanceOf
Returns the token balance of account
.
Parameters
account
address
The address of some account.
Returns
<none>
uint256
The token balance of account
.
decimals
Returns the number of decimals UIs should assume all amounts have.
name
Returns the name of the contract/token.
symbol
Returns the symbol of the token.
totalSupply
Returns the current total supply of the token.
Events
Approval
Emitted when spender
has been approved for amount
of the token balance of account
.
Parameters
account
address
The address of the account.
spender
address
The address of the spender being approved for the allowance.
amount
uint256
The amount of the allowance being approved.
Transfer
Emitted when amount
tokens is transferred from sender
to recipient
.
Parameters
sender
address
The address of the sender who's token balance is decremented.
recipient
address
The address of the recipient who's token balance is incremented.
amount
uint256
The amount of tokens being transferred.