ERC721Receiver
contract ERC721Receiver
Interface for any contract that wants to support safeTransfers from ERC721 asset contracts.
Source: token/ERC721/ERC721Receiver.sol
Index
Reference
Functions
onERC721Received
abstract function onERC721Received(address _operator, address _from, uint256 _tokenId, bytes _data) public returns (bytes4)
The ERC721 smart contract calls this function on the recipient after a `safetransfer`. This function MAY throw to revert and reject the transfer. Return of other than the magic value MUST result in the transaction being reverted. Note: the contract address is always the message sender., Handle the receipt of an NFT.
- Parameters:
_operator
- The address which called `safeTransferFrom` function_from
- The address which previously owned the token_tokenId
- The NFT identifier which is being transfered_data
- Additional data with no specified format- Returns:
- `bytes4(keccak256("onERC721Received(address,address,uint256,bytes)"))`