ODCdataManagersomnichainERC721extensions

OmnichainERC721Transfers

Abstract contract that provides Omnichain ERC721 transfer functions of the Omnichain ERC721 Data Manager

Based on OpenZeppelin ERC721 implementation

safeTransferFrom

function safeTransferFrom(address from, OmnichainAddress to, uint256 tokenId, bytes data) public payable virtual

Transfers an tokenId from from to to in another chain

The caller must have allowance for from's token or be from Caller may receive native coin refund, so if it's a contract it MUST have receive() or payable fallback()

Parameters

NameTypeDescription
fromaddressSource address
toOmnichainAddressDestination omnichain address
tokenIduint256Token ID
databytesAdditional data with no specified format

safeTransferFrom

function safeTransferFrom(address from, OmnichainAddress to, uint256 tokenId, bytes data, address payable refundAddress) public payable virtual

Transfers an tokenId from from to to in another chain

The caller must have allowance for from's token or be from

Parameters

NameTypeDescription
fromaddressSource address
toOmnichainAddressDestination omnichain address
tokenIduint256Token ID
databytesAdditional data with no specified format
refundAddressaddress payableAddress to send native coin refund to

_writeTransfer

function _writeTransfer(address from, OmnichainAddress to, uint256 tokenId, address payable refundAddress) internal virtual

_safeTransferFrom

function _safeTransferFrom(address from, OmnichainAddress to, uint256 tokenId, bytes, address payable refundAddress) internal

_update

function _update(OmnichainAddress to, uint256 tokenId, address auth, address payable refundAddress) internal virtual returns (address)

On this page