State Variables
baseUri
Base Contract URIcounter
Functions
constructor
Constructor for the Example ERC721 token. Initializes the token with a name and symbol.Name | Type | Description |
---|---|---|
_name | string | The name of the token. |
_symbol | string | The symbol of the token. |
setCallingContractAdmin
Override the default setCallingContractAdmin and add onlyOwner modifier to prevent unauthorized accesssafeMint
Mints a new token to the specified address. The token ID is incremented by 1 from the previous minted token. This function is payable to allow child contracts to override it with a priced mint function.Name | Type | Description |
---|---|---|
to | address | The address of the recipient. |
safeTransferFrom
Safely transfers a token from one address to another. This function overrides the ERC721-safeTransferFrom function and interacts with the Rules Engine to ensure compliance with transfer policies. It includes additional checks for policy compliance.Name | Type | Description |
---|---|---|
from | address | The address of the current token owner. |
to | address | The address of the recipient. |
tokenId | uint256 | The ID of the token to transfer. |
data | bytes | Additional data to pass to the recipient contract. |
transferFrom
Transfers a token from one address to another. This function overrides the ERC721-transferFrom function and interacts with the Rules Engine to ensure compliance with transfer policies. It includes additional checks for policy compliance.Name | Type | Description |
---|---|---|
from | address | The address of the current token owner. |
to | address | The address of the recipient. |
tokenId | uint256 | The ID of the token to transfer. |
supportsInterface
Returns true if this contract implements the interface defined byinterfaceId
. See the corresponding
https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section]
to learn more about how these ids are created.
This function call must use less than 30 000 gas.