ODCinterfacesdataobject-interfaces

INonFungibleTokenOperations

Provides the operations of the NonFungibleTokenDO to interact with non fungible tokens and their associated data

balanceOf

function balanceOf(address account) external view returns (uint256)

Operation used to get the balance of an account

Parameters

NameTypeDescription
accountaddressThe account address

Return Values

NameTypeDescription
[0]uint256The balance of the account

ownerOf

function ownerOf(uint256 tokenId) external view returns (address)

Operation used to get the owner of a token

Parameters

NameTypeDescription
tokenIduint256The token id

Return Values

NameTypeDescription
[0]addressThe owner of the token

mint

function mint(address to, uint256 tokenId) external

Operation used to mint new tokens

Parameters

NameTypeDescription
toaddressThe account address to mint the tokens to
tokenIduint256The tokenId of tokens to mint

burn

function burn(address from, uint256 tokenId) external

Operation used to burn tokens

Parameters

NameTypeDescription
fromaddressThe account address to burn the tokens from
tokenIduint256The tokenId of tokens to burn

transferFrom

function transferFrom(address from, address to, uint256 tokenId) external

Operation used to transfer tokens

Parameters

NameTypeDescription
fromaddressThe account address to transfer the tokens from
toaddressThe account address to transfer the tokens to
tokenIduint256The tokenId of tokens to transfer

batchTransferFromMultipleIds

function batchTransferFromMultipleIds(address from, address to, uint256[] tokenIds) external

Operation used to transfer batch of tokens

Parameters

NameTypeDescription
fromaddressThe account address to transfer the tokens from
toaddressThe account address to transfer the tokens to
tokenIdsuint256[]The tokenIds of tokens to transfer

batchTransferFromMultipleTargetsIds

function batchTransferFromMultipleTargetsIds(address from, address[] to, uint256[] tokenIds) external

Operation used to transfer batch of tokens

Parameters

NameTypeDescription
fromaddressThe account address to transfer the tokens from
toaddress[]The accounts addresses to transfer the tokens to
tokenIdsuint256[]The tokenIds of tokens to transfer

On this page