balanceOf
function on the token contract using the provided selector and decodes
the returned data to retrieve the balance
Name | Type | Description |
---|---|---|
token | address | The address of the token contract |
user | address | The address of the user to query |
Name | Type | Description |
---|---|---|
<none> | uint256 | The balance of tokens held by the user |
transfer
function on the specified token contract and checks for successful transfer
Name | Type | Description |
---|---|---|
token | address | The contract address of the token which will be transferred |
to | address | The recipient of the transfer |
value | uint256 | The amount of tokens to be transferred |
transferFrom
function
Calls the transferFrom
function on the specified token contract and checks for successful transfer
Name | Type | Description |
---|---|---|
token | address | The contract address of the token which will be transferred |
from | address | The source address from which tokens will be transferred |
to | address | The recipient address to which tokens will be transferred |
value | uint256 | The amount of tokens to be transferred |