UNPKG

@etherisc/gif-contracts

Version:

This repository holds the GIF core contracts and tools to develop, test and deploy GIF instances.

715 lines 22.5 kB
{ "abi": [ { "anonymous": false, "inputs": [ { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, { "indexed": true, "internalType": "address", "name": "approved", "type": "address" }, { "indexed": true, "internalType": "uint256", "name": "tokenId", "type": "uint256" } ], "name": "Approval", "type": "event" }, { "anonymous": false, "inputs": [ { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, { "indexed": true, "internalType": "address", "name": "operator", "type": "address" }, { "indexed": false, "internalType": "bool", "name": "approved", "type": "bool" } ], "name": "ApprovalForAll", "type": "event" }, { "anonymous": false, "inputs": [ { "indexed": true, "internalType": "address", "name": "from", "type": "address" }, { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, { "indexed": true, "internalType": "uint256", "name": "tokenId", "type": "uint256" } ], "name": "Transfer", "type": "event" }, { "inputs": [ { "internalType": "address", "name": "to", "type": "address" }, { "internalType": "uint256", "name": "tokenId", "type": "uint256" } ], "name": "approve", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [ { "internalType": "address", "name": "owner", "type": "address" } ], "name": "balanceOf", "outputs": [ { "internalType": "uint256", "name": "balance", "type": "uint256" } ], "stateMutability": "view", "type": "function" }, { "inputs": [ { "internalType": "uint256", "name": "tokenId", "type": "uint256" } ], "name": "getApproved", "outputs": [ { "internalType": "address", "name": "operator", "type": "address" } ], "stateMutability": "view", "type": "function" }, { "inputs": [ { "internalType": "address", "name": "owner", "type": "address" }, { "internalType": "address", "name": "operator", "type": "address" } ], "name": "isApprovedForAll", "outputs": [ { "internalType": "bool", "name": "", "type": "bool" } ], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "name", "outputs": [ { "internalType": "string", "name": "", "type": "string" } ], "stateMutability": "view", "type": "function" }, { "inputs": [ { "internalType": "uint256", "name": "tokenId", "type": "uint256" } ], "name": "ownerOf", "outputs": [ { "internalType": "address", "name": "owner", "type": "address" } ], "stateMutability": "view", "type": "function" }, { "inputs": [ { "internalType": "address", "name": "from", "type": "address" }, { "internalType": "address", "name": "to", "type": "address" }, { "internalType": "uint256", "name": "tokenId", "type": "uint256" } ], "name": "safeTransferFrom", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [ { "internalType": "address", "name": "from", "type": "address" }, { "internalType": "address", "name": "to", "type": "address" }, { "internalType": "uint256", "name": "tokenId", "type": "uint256" }, { "internalType": "bytes", "name": "data", "type": "bytes" } ], "name": "safeTransferFrom", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [ { "internalType": "address", "name": "operator", "type": "address" }, { "internalType": "bool", "name": "_approved", "type": "bool" } ], "name": "setApprovalForAll", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [ { "internalType": "bytes4", "name": "interfaceId", "type": "bytes4" } ], "name": "supportsInterface", "outputs": [ { "internalType": "bool", "name": "", "type": "bool" } ], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "symbol", "outputs": [ { "internalType": "string", "name": "", "type": "string" } ], "stateMutability": "view", "type": "function" }, { "inputs": [ { "internalType": "uint256", "name": "tokenId", "type": "uint256" } ], "name": "tokenURI", "outputs": [ { "internalType": "string", "name": "", "type": "string" } ], "stateMutability": "view", "type": "function" }, { "inputs": [ { "internalType": "address", "name": "from", "type": "address" }, { "internalType": "address", "name": "to", "type": "address" }, { "internalType": "uint256", "name": "tokenId", "type": "uint256" } ], "name": "transferFrom", "outputs": [], "stateMutability": "nonpayable", "type": "function" } ], "allSourcePaths": { "18": "/home/vscode/.brownie/packages/OpenZeppelin/openzeppelin-contracts@4.7.3/contracts/token/ERC721/IERC721.sol", "20": "/home/vscode/.brownie/packages/OpenZeppelin/openzeppelin-contracts@4.7.3/contracts/token/ERC721/extensions/IERC721Metadata.sol", "26": "/home/vscode/.brownie/packages/OpenZeppelin/openzeppelin-contracts@4.7.3/contracts/utils/introspection/IERC165.sol" }, "ast": { "absolutePath": "/home/vscode/.brownie/packages/OpenZeppelin/openzeppelin-contracts@4.7.3/contracts/token/ERC721/extensions/IERC721Metadata.sol", "exportedSymbols": { "IERC165": [ 27203 ], "IERC721": [ 23745 ], "IERC721Metadata": [ 27618 ] }, "id": 27619, "license": "MIT", "nodeType": "SourceUnit", "nodes": [ { "id": 27593, "literals": [ "solidity", "^", "0.8", ".0" ], "nodeType": "PragmaDirective", "src": "112:23:20" }, { "absolutePath": "/home/vscode/.brownie/packages/OpenZeppelin/openzeppelin-contracts@4.7.3/contracts/token/ERC721/IERC721.sol", "file": "../IERC721.sol", "id": 27594, "nameLocation": "-1:-1:-1", "nodeType": "ImportDirective", "scope": 27619, "sourceUnit": 23746, "src": "137:24:20", "symbolAliases": [], "unitAlias": "" }, { "abstract": false, "baseContracts": [ { "baseName": { "id": 27596, "name": "IERC721", "nodeType": "IdentifierPath", "referencedDeclaration": 23745, "src": "326:7:20" }, "id": 27597, "nodeType": "InheritanceSpecifier", "src": "326:7:20" } ], "contractDependencies": [ 23745, 27203 ], "contractKind": "interface", "documentation": { "id": 27595, "nodeType": "StructuredDocumentation", "src": "163:133:20", "text": " @title ERC-721 Non-Fungible Token Standard, optional metadata extension\n @dev See https://eips.ethereum.org/EIPS/eip-721" }, "fullyImplemented": false, "id": 27618, "linearizedBaseContracts": [ 27618, 23745, 27203 ], "name": "IERC721Metadata", "nameLocation": "307:15:20", "nodeType": "ContractDefinition", "nodes": [ { "documentation": { "id": 27598, "nodeType": "StructuredDocumentation", "src": "340:58:20", "text": " @dev Returns the token collection name." }, "functionSelector": "06fdde03", "id": 27603, "implemented": false, "kind": "function", "modifiers": [], "name": "name", "nameLocation": "412:4:20", "nodeType": "FunctionDefinition", "parameters": { "id": 27599, "nodeType": "ParameterList", "parameters": [], "src": "416:2:20" }, "returnParameters": { "id": 27602, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 27601, "mutability": "mutable", "name": "", "nameLocation": "-1:-1:-1", "nodeType": "VariableDeclaration", "scope": 27603, "src": "442:13:20", "stateVariable": false, "storageLocation": "memory", "typeDescriptions": { "typeIdentifier": "t_string_memory_ptr", "typeString": "string" }, "typeName": { "id": 27600, "name": "string", "nodeType": "ElementaryTypeName", "src": "442:6:20", "typeDescriptions": { "typeIdentifier": "t_string_storage_ptr", "typeString": "string" } }, "visibility": "internal" } ], "src": "441:15:20" }, "scope": 27618, "src": "403:54:20", "stateMutability": "view", "virtual": false, "visibility": "external" }, { "documentation": { "id": 27604, "nodeType": "StructuredDocumentation", "src": "463:60:20", "text": " @dev Returns the token collection symbol." }, "functionSelector": "95d89b41", "id": 27609, "implemented": false, "kind": "function", "modifiers": [], "name": "symbol", "nameLocation": "537:6:20", "nodeType": "FunctionDefinition", "parameters": { "id": 27605, "nodeType": "ParameterList", "parameters": [], "src": "543:2:20" }, "returnParameters": { "id": 27608, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 27607, "mutability": "mutable", "name": "", "nameLocation": "-1:-1:-1", "nodeType": "VariableDeclaration", "scope": 27609, "src": "569:13:20", "stateVariable": false, "storageLocation": "memory", "typeDescriptions": { "typeIdentifier": "t_string_memory_ptr", "typeString": "string" }, "typeName": { "id": 27606, "name": "string", "nodeType": "ElementaryTypeName", "src": "569:6:20", "typeDescriptions": { "typeIdentifier": "t_string_storage_ptr", "typeString": "string" } }, "visibility": "internal" } ], "src": "568:15:20" }, "scope": 27618, "src": "528:56:20", "stateMutability": "view", "virtual": false, "visibility": "external" }, { "documentation": { "id": 27610, "nodeType": "StructuredDocumentation", "src": "590:90:20", "text": " @dev Returns the Uniform Resource Identifier (URI) for `tokenId` token." }, "functionSelector": "c87b56dd", "id": 27617, "implemented": false, "kind": "function", "modifiers": [], "name": "tokenURI", "nameLocation": "694:8:20", "nodeType": "FunctionDefinition", "parameters": { "id": 27613, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 27612, "mutability": "mutable", "name": "tokenId", "nameLocation": "711:7:20", "nodeType": "VariableDeclaration", "scope": 27617, "src": "703:15:20", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 27611, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "703:7:20", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "visibility": "internal" } ], "src": "702:17:20" }, "returnParameters": { "id": 27616, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 27615, "mutability": "mutable", "name": "", "nameLocation": "-1:-1:-1", "nodeType": "VariableDeclaration", "scope": 27617, "src": "743:13:20", "stateVariable": false, "storageLocation": "memory", "typeDescriptions": { "typeIdentifier": "t_string_memory_ptr", "typeString": "string" }, "typeName": { "id": 27614, "name": "string", "nodeType": "ElementaryTypeName", "src": "743:6:20", "typeDescriptions": { "typeIdentifier": "t_string_storage_ptr", "typeString": "string" } }, "visibility": "internal" } ], "src": "742:15:20" }, "scope": 27618, "src": "685:73:20", "stateMutability": "view", "virtual": false, "visibility": "external" } ], "scope": 27619, "src": "297:463:20" } ], "src": "112:649:20" }, "bytecode": "", "bytecodeSha1": "da39a3ee5e6b4b0d3255bfef95601890afd80709", "compiler": { "evm_version": "istanbul", "optimizer": { "enabled": true, "runs": 200 }, "version": "0.8.2+commit.661d1103" }, "contractName": "IERC721Metadata", "coverageMap": { "branches": {}, "statements": {} }, "dependencies": [ "OpenZeppelin/openzeppelin-contracts@4.7.3/IERC165", "OpenZeppelin/openzeppelin-contracts@4.7.3/IERC721" ], "deployedBytecode": "", "deployedSourceMap": "", "language": "Solidity", "natspec": { "details": "See https://eips.ethereum.org/EIPS/eip-721", "kind": "dev", "methods": { "approve(address,uint256)": { "details": "Gives permission to `to` to transfer `tokenId` token to another account. The approval is cleared when the token is transferred. Only a single account can be approved at a time, so approving the zero address clears previous approvals. Requirements: - The caller must own the token or be an approved operator. - `tokenId` must exist. Emits an {Approval} event." }, "balanceOf(address)": { "details": "Returns the number of tokens in ``owner``'s account." }, "getApproved(uint256)": { "details": "Returns the account approved for `tokenId` token. Requirements: - `tokenId` must exist." }, "isApprovedForAll(address,address)": { "details": "Returns if the `operator` is allowed to manage all of the assets of `owner`. See {setApprovalForAll}" }, "name()": { "details": "Returns the token collection name." }, "ownerOf(uint256)": { "details": "Returns the owner of the `tokenId` token. Requirements: - `tokenId` must exist." }, "safeTransferFrom(address,address,uint256)": { "details": "Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients are aware of the ERC721 protocol to prevent tokens from being forever locked. Requirements: - `from` cannot be the zero address. - `to` cannot be the zero address. - `tokenId` token must exist and be owned by `from`. - If the caller is not `from`, it must have been allowed to move this token by either {approve} or {setApprovalForAll}. - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. Emits a {Transfer} event." }, "safeTransferFrom(address,address,uint256,bytes)": { "details": "Safely transfers `tokenId` token from `from` to `to`. Requirements: - `from` cannot be the zero address. - `to` cannot be the zero address. - `tokenId` token must exist and be owned by `from`. - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}. - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. Emits a {Transfer} event." }, "setApprovalForAll(address,bool)": { "details": "Approve or remove `operator` as an operator for the caller. Operators can call {transferFrom} or {safeTransferFrom} for any token owned by the caller. Requirements: - The `operator` cannot be the caller. Emits an {ApprovalForAll} event." }, "supportsInterface(bytes4)": { "details": "Returns true if this contract implements the interface defined by `interfaceId`. 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." }, "symbol()": { "details": "Returns the token collection symbol." }, "tokenURI(uint256)": { "details": "Returns the Uniform Resource Identifier (URI) for `tokenId` token." }, "transferFrom(address,address,uint256)": { "details": "Transfers `tokenId` token from `from` to `to`. WARNING: Usage of this method is discouraged, use {safeTransferFrom} whenever possible. Requirements: - `from` cannot be the zero address. - `to` cannot be the zero address. - `tokenId` token must be owned by `from`. - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}. Emits a {Transfer} event." } }, "title": "ERC-721 Non-Fungible Token Standard, optional metadata extension", "version": 1 }, "offset": [ 297, 760 ], "opcodes": "", "pcMap": {}, "sha1": "f2961c701500b017eb65f22ae6a5bc46486b959a", "source": "// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts v4.4.1 (token/ERC721/extensions/IERC721Metadata.sol)\n\npragma solidity ^0.8.0;\n\nimport \"../IERC721.sol\";\n\n/**\n * @title ERC-721 Non-Fungible Token Standard, optional metadata extension\n * @dev See https://eips.ethereum.org/EIPS/eip-721\n */\ninterface IERC721Metadata is IERC721 {\n /**\n * @dev Returns the token collection name.\n */\n function name() external view returns (string memory);\n\n /**\n * @dev Returns the token collection symbol.\n */\n function symbol() external view returns (string memory);\n\n /**\n * @dev Returns the Uniform Resource Identifier (URI) for `tokenId` token.\n */\n function tokenURI(uint256 tokenId) external view returns (string memory);\n}\n", "sourceMap": "", "sourcePath": "/home/vscode/.brownie/packages/OpenZeppelin/openzeppelin-contracts@4.7.3/contracts/token/ERC721/extensions/IERC721Metadata.sol", "type": "interface" }