class IERC677
Defines the interface for an ERC677 token contract.
Extends the standard ERC20 interface with the additional transferAndCall
method, enabling token transfers that also trigger contract calls.
{IERC20}
Methods
transferAndCall(to, value, data0, data1, data2, data3)
Transfers tokens to a recipient and calls a contract method.
Name | Type | Description |
---|---|---|
|
|
The address of the recipient. |
|
|
The amount of tokens to transfer. |
|
|
The first additional field to be passed to the contract method, if applicable. |
|
|
The second additional field to be passed to the contract method, if applicable. |
|
|
The third additional field to be passed to the contract method, if applicable. |
|
|
The fourth additional field to be passed to the contract method, if applicable. |
Returns |
|
{Bool} - True if the transfer and call were successful, false otherwise. Transfer - Emitted when the transfer is successful. |
abstract transferAndCall(to: PublicKey, value: UInt64, data0: Field, data1: Field, data2: Field, data3: Field): Promise<void>;