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 _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. This function MUST use 50,000 gas or less. 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:
_from
- The sending address_tokenId
- The NFT identifier which is being transfered_data
- Additional data with no specified format- Returns:
- `bytes4(keccak256("onERC721Received(address,uint256,bytes)"))`