UNPKG

@etherisc/terraguard-poc-contracts

Version:

Etherisc's smart contracts for the terraguard poc

1,455 lines (1,454 loc) 66.6 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": [ { "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": [ { "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": { "4": "/home/runner/.brownie/packages/OpenZeppelin/openzeppelin-contracts@4.8.2/contracts/token/ERC721/IERC721.sol", "6": "/home/runner/.brownie/packages/OpenZeppelin/openzeppelin-contracts@4.8.2/contracts/utils/introspection/IERC165.sol" }, "ast": { "absolutePath": "/home/runner/.brownie/packages/OpenZeppelin/openzeppelin-contracts@4.8.2/contracts/token/ERC721/IERC721.sol", "exportedSymbols": { "IERC165": [ 7662 ], "IERC721": [ 6660 ] }, "id": 6661, "license": "MIT", "nodeType": "SourceUnit", "nodes": [ { "id": 6546, "literals": [ "solidity", "^", "0.8", ".0" ], "nodeType": "PragmaDirective", "src": "108:23:4" }, { "absolutePath": "/home/runner/.brownie/packages/OpenZeppelin/openzeppelin-contracts@4.8.2/contracts/utils/introspection/IERC165.sol", "file": "../../utils/introspection/IERC165.sol", "id": 6547, "nameLocation": "-1:-1:-1", "nodeType": "ImportDirective", "scope": 6661, "sourceUnit": 7663, "src": "133:47:4", "symbolAliases": [], "unitAlias": "" }, { "abstract": false, "baseContracts": [ { "baseName": { "id": 6549, "name": "IERC165", "nodeType": "IdentifierPath", "referencedDeclaration": 7662, "src": "271:7:4" }, "id": 6550, "nodeType": "InheritanceSpecifier", "src": "271:7:4" } ], "contractDependencies": [ 7662 ], "contractKind": "interface", "documentation": { "id": 6548, "nodeType": "StructuredDocumentation", "src": "182:67:4", "text": " @dev Required interface of an ERC721 compliant contract." }, "fullyImplemented": false, "id": 6660, "linearizedBaseContracts": [ 6660, 7662 ], "name": "IERC721", "nameLocation": "260:7:4", "nodeType": "ContractDefinition", "nodes": [ { "anonymous": false, "documentation": { "id": 6551, "nodeType": "StructuredDocumentation", "src": "285:88:4", "text": " @dev Emitted when `tokenId` token is transferred from `from` to `to`." }, "id": 6559, "name": "Transfer", "nameLocation": "384:8:4", "nodeType": "EventDefinition", "parameters": { "id": 6558, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 6553, "indexed": true, "mutability": "mutable", "name": "from", "nameLocation": "409:4:4", "nodeType": "VariableDeclaration", "scope": 6559, "src": "393:20:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 6552, "name": "address", "nodeType": "ElementaryTypeName", "src": "393:7:4", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "visibility": "internal" }, { "constant": false, "id": 6555, "indexed": true, "mutability": "mutable", "name": "to", "nameLocation": "431:2:4", "nodeType": "VariableDeclaration", "scope": 6559, "src": "415:18:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 6554, "name": "address", "nodeType": "ElementaryTypeName", "src": "415:7:4", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "visibility": "internal" }, { "constant": false, "id": 6557, "indexed": true, "mutability": "mutable", "name": "tokenId", "nameLocation": "451:7:4", "nodeType": "VariableDeclaration", "scope": 6559, "src": "435:23:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 6556, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "435:7:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "visibility": "internal" } ], "src": "392:67:4" }, "src": "378:82:4" }, { "anonymous": false, "documentation": { "id": 6560, "nodeType": "StructuredDocumentation", "src": "466:94:4", "text": " @dev Emitted when `owner` enables `approved` to manage the `tokenId` token." }, "id": 6568, "name": "Approval", "nameLocation": "571:8:4", "nodeType": "EventDefinition", "parameters": { "id": 6567, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 6562, "indexed": true, "mutability": "mutable", "name": "owner", "nameLocation": "596:5:4", "nodeType": "VariableDeclaration", "scope": 6568, "src": "580:21:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 6561, "name": "address", "nodeType": "ElementaryTypeName", "src": "580:7:4", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "visibility": "internal" }, { "constant": false, "id": 6564, "indexed": true, "mutability": "mutable", "name": "approved", "nameLocation": "619:8:4", "nodeType": "VariableDeclaration", "scope": 6568, "src": "603:24:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 6563, "name": "address", "nodeType": "ElementaryTypeName", "src": "603:7:4", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "visibility": "internal" }, { "constant": false, "id": 6566, "indexed": true, "mutability": "mutable", "name": "tokenId", "nameLocation": "645:7:4", "nodeType": "VariableDeclaration", "scope": 6568, "src": "629:23:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 6565, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "629:7:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "visibility": "internal" } ], "src": "579:74:4" }, "src": "565:89:4" }, { "anonymous": false, "documentation": { "id": 6569, "nodeType": "StructuredDocumentation", "src": "660:117:4", "text": " @dev Emitted when `owner` enables or disables (`approved`) `operator` to manage all of its assets." }, "id": 6577, "name": "ApprovalForAll", "nameLocation": "788:14:4", "nodeType": "EventDefinition", "parameters": { "id": 6576, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 6571, "indexed": true, "mutability": "mutable", "name": "owner", "nameLocation": "819:5:4", "nodeType": "VariableDeclaration", "scope": 6577, "src": "803:21:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 6570, "name": "address", "nodeType": "ElementaryTypeName", "src": "803:7:4", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "visibility": "internal" }, { "constant": false, "id": 6573, "indexed": true, "mutability": "mutable", "name": "operator", "nameLocation": "842:8:4", "nodeType": "VariableDeclaration", "scope": 6577, "src": "826:24:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 6572, "name": "address", "nodeType": "ElementaryTypeName", "src": "826:7:4", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "visibility": "internal" }, { "constant": false, "id": 6575, "indexed": false, "mutability": "mutable", "name": "approved", "nameLocation": "857:8:4", "nodeType": "VariableDeclaration", "scope": 6577, "src": "852:13:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" }, "typeName": { "id": 6574, "name": "bool", "nodeType": "ElementaryTypeName", "src": "852:4:4", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "visibility": "internal" } ], "src": "802:64:4" }, "src": "782:85:4" }, { "documentation": { "id": 6578, "nodeType": "StructuredDocumentation", "src": "873:76:4", "text": " @dev Returns the number of tokens in ``owner``'s account." }, "functionSelector": "70a08231", "id": 6585, "implemented": false, "kind": "function", "modifiers": [], "name": "balanceOf", "nameLocation": "963:9:4", "nodeType": "FunctionDefinition", "parameters": { "id": 6581, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 6580, "mutability": "mutable", "name": "owner", "nameLocation": "981:5:4", "nodeType": "VariableDeclaration", "scope": 6585, "src": "973:13:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 6579, "name": "address", "nodeType": "ElementaryTypeName", "src": "973:7:4", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "visibility": "internal" } ], "src": "972:15:4" }, "returnParameters": { "id": 6584, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 6583, "mutability": "mutable", "name": "balance", "nameLocation": "1019:7:4", "nodeType": "VariableDeclaration", "scope": 6585, "src": "1011:15:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 6582, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "1011:7:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "visibility": "internal" } ], "src": "1010:17:4" }, "scope": 6660, "src": "954:74:4", "stateMutability": "view", "virtual": false, "visibility": "external" }, { "documentation": { "id": 6586, "nodeType": "StructuredDocumentation", "src": "1034:131:4", "text": " @dev Returns the owner of the `tokenId` token.\n Requirements:\n - `tokenId` must exist." }, "functionSelector": "6352211e", "id": 6593, "implemented": false, "kind": "function", "modifiers": [], "name": "ownerOf", "nameLocation": "1179:7:4", "nodeType": "FunctionDefinition", "parameters": { "id": 6589, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 6588, "mutability": "mutable", "name": "tokenId", "nameLocation": "1195:7:4", "nodeType": "VariableDeclaration", "scope": 6593, "src": "1187:15:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 6587, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "1187:7:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "visibility": "internal" } ], "src": "1186:17:4" }, "returnParameters": { "id": 6592, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 6591, "mutability": "mutable", "name": "owner", "nameLocation": "1235:5:4", "nodeType": "VariableDeclaration", "scope": 6593, "src": "1227:13:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 6590, "name": "address", "nodeType": "ElementaryTypeName", "src": "1227:7:4", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "visibility": "internal" } ], "src": "1226:15:4" }, "scope": 6660, "src": "1170:72:4", "stateMutability": "view", "virtual": false, "visibility": "external" }, { "documentation": { "id": 6594, "nodeType": "StructuredDocumentation", "src": "1248:556:4", "text": " @dev Safely transfers `tokenId` token from `from` to `to`.\n Requirements:\n - `from` cannot be the zero address.\n - `to` cannot be the zero address.\n - `tokenId` token must exist and be owned by `from`.\n - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}.\n - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.\n Emits a {Transfer} event." }, "functionSelector": "b88d4fde", "id": 6605, "implemented": false, "kind": "function", "modifiers": [], "name": "safeTransferFrom", "nameLocation": "1818:16:4", "nodeType": "FunctionDefinition", "parameters": { "id": 6603, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 6596, "mutability": "mutable", "name": "from", "nameLocation": "1852:4:4", "nodeType": "VariableDeclaration", "scope": 6605, "src": "1844:12:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 6595, "name": "address", "nodeType": "ElementaryTypeName", "src": "1844:7:4", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "visibility": "internal" }, { "constant": false, "id": 6598, "mutability": "mutable", "name": "to", "nameLocation": "1874:2:4", "nodeType": "VariableDeclaration", "scope": 6605, "src": "1866:10:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 6597, "name": "address", "nodeType": "ElementaryTypeName", "src": "1866:7:4", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "visibility": "internal" }, { "constant": false, "id": 6600, "mutability": "mutable", "name": "tokenId", "nameLocation": "1894:7:4", "nodeType": "VariableDeclaration", "scope": 6605, "src": "1886:15:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 6599, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "1886:7:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "visibility": "internal" }, { "constant": false, "id": 6602, "mutability": "mutable", "name": "data", "nameLocation": "1926:4:4", "nodeType": "VariableDeclaration", "scope": 6605, "src": "1911:19:4", "stateVariable": false, "storageLocation": "calldata", "typeDescriptions": { "typeIdentifier": "t_bytes_calldata_ptr", "typeString": "bytes" }, "typeName": { "id": 6601, "name": "bytes", "nodeType": "ElementaryTypeName", "src": "1911:5:4", "typeDescriptions": { "typeIdentifier": "t_bytes_storage_ptr", "typeString": "bytes" } }, "visibility": "internal" } ], "src": "1834:102:4" }, "returnParameters": { "id": 6604, "nodeType": "ParameterList", "parameters": [], "src": "1945:0:4" }, "scope": 6660, "src": "1809:137:4", "stateMutability": "nonpayable", "virtual": false, "visibility": "external" }, { "documentation": { "id": 6606, "nodeType": "StructuredDocumentation", "src": "1952:687:4", "text": " @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients\n are aware of the ERC721 protocol to prevent tokens from being forever locked.\n Requirements:\n - `from` cannot be the zero address.\n - `to` cannot be the zero address.\n - `tokenId` token must exist and be owned by `from`.\n - If the caller is not `from`, it must have been allowed to move this token by either {approve} or {setApprovalForAll}.\n - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.\n Emits a {Transfer} event." }, "functionSelector": "42842e0e", "id": 6615, "implemented": false, "kind": "function", "modifiers": [], "name": "safeTransferFrom", "nameLocation": "2653:16:4", "nodeType": "FunctionDefinition", "parameters": { "id": 6613, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 6608, "mutability": "mutable", "name": "from", "nameLocation": "2687:4:4", "nodeType": "VariableDeclaration", "scope": 6615, "src": "2679:12:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 6607, "name": "address", "nodeType": "ElementaryTypeName", "src": "2679:7:4", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "visibility": "internal" }, { "constant": false, "id": 6610, "mutability": "mutable", "name": "to", "nameLocation": "2709:2:4", "nodeType": "VariableDeclaration", "scope": 6615, "src": "2701:10:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 6609, "name": "address", "nodeType": "ElementaryTypeName", "src": "2701:7:4", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "visibility": "internal" }, { "constant": false, "id": 6612, "mutability": "mutable", "name": "tokenId", "nameLocation": "2729:7:4", "nodeType": "VariableDeclaration", "scope": 6615, "src": "2721:15:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 6611, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "2721:7:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "visibility": "internal" } ], "src": "2669:73:4" }, "returnParameters": { "id": 6614, "nodeType": "ParameterList", "parameters": [], "src": "2751:0:4" }, "scope": 6660, "src": "2644:108:4", "stateMutability": "nonpayable", "virtual": false, "visibility": "external" }, { "documentation": { "id": 6616, "nodeType": "StructuredDocumentation", "src": "2758:732:4", "text": " @dev Transfers `tokenId` token from `from` to `to`.\n WARNING: Note that the caller is responsible to confirm that the recipient is capable of receiving ERC721\n or else they may be permanently lost. Usage of {safeTransferFrom} prevents loss, though the caller must\n understand this adds an external call which potentially creates a reentrancy vulnerability.\n Requirements:\n - `from` cannot be the zero address.\n - `to` cannot be the zero address.\n - `tokenId` token must be owned by `from`.\n - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}.\n Emits a {Transfer} event." }, "functionSelector": "23b872dd", "id": 6625, "implemented": false, "kind": "function", "modifiers": [], "name": "transferFrom", "nameLocation": "3504:12:4", "nodeType": "FunctionDefinition", "parameters": { "id": 6623, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 6618, "mutability": "mutable", "name": "from", "nameLocation": "3534:4:4", "nodeType": "VariableDeclaration", "scope": 6625, "src": "3526:12:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 6617, "name": "address", "nodeType": "ElementaryTypeName", "src": "3526:7:4", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "visibility": "internal" }, { "constant": false, "id": 6620, "mutability": "mutable", "name": "to", "nameLocation": "3556:2:4", "nodeType": "VariableDeclaration", "scope": 6625, "src": "3548:10:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 6619, "name": "address", "nodeType": "ElementaryTypeName", "src": "3548:7:4", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "visibility": "internal" }, { "constant": false, "id": 6622, "mutability": "mutable", "name": "tokenId", "nameLocation": "3576:7:4", "nodeType": "VariableDeclaration", "scope": 6625, "src": "3568:15:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 6621, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "3568:7:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "visibility": "internal" } ], "src": "3516:73:4" }, "returnParameters": { "id": 6624, "nodeType": "ParameterList", "parameters": [], "src": "3598:0:4" }, "scope": 6660, "src": "3495:104:4", "stateMutability": "nonpayable", "virtual": false, "visibility": "external" }, { "documentation": { "id": 6626, "nodeType": "StructuredDocumentation", "src": "3605:452:4", "text": " @dev Gives permission to `to` to transfer `tokenId` token to another account.\n The approval is cleared when the token is transferred.\n Only a single account can be approved at a time, so approving the zero address clears previous approvals.\n Requirements:\n - The caller must own the token or be an approved operator.\n - `tokenId` must exist.\n Emits an {Approval} event." }, "functionSelector": "095ea7b3", "id": 6633, "implemented": false, "kind": "function", "modifiers": [], "name": "approve", "nameLocation": "4071:7:4", "nodeType": "FunctionDefinition", "parameters": { "id": 6631, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 6628, "mutability": "mutable", "name": "to", "nameLocation": "4087:2:4", "nodeType": "VariableDeclaration", "scope": 6633, "src": "4079:10:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 6627, "name": "address", "nodeType": "ElementaryTypeName", "src": "4079:7:4", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "visibility": "internal" }, { "constant": false, "id": 6630, "mutability": "mutable", "name": "tokenId", "nameLocation": "4099:7:4", "nodeType": "VariableDeclaration", "scope": 6633, "src": "4091:15:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 6629, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "4091:7:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "visibility": "internal" } ], "src": "4078:29:4" }, "returnParameters": { "id": 6632, "nodeType": "ParameterList", "parameters": [], "src": "4116:0:4" }, "scope": 6660, "src": "4062:55:4", "stateMutability": "nonpayable", "virtual": false, "visibility": "external" }, { "documentation": { "id": 6634, "nodeType": "StructuredDocumentation", "src": "4123:309:4", "text": " @dev Approve or remove `operator` as an operator for the caller.\n Operators can call {transferFrom} or {safeTransferFrom} for any token owned by the caller.\n Requirements:\n - The `operator` cannot be the caller.\n Emits an {ApprovalForAll} event." }, "functionSelector": "a22cb465", "id": 6641, "implemented": false, "kind": "function", "modifiers": [], "name": "setApprovalForAll", "nameLocation": "4446:17:4", "nodeType": "FunctionDefinition", "parameters": { "id": 6639, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 6636, "mutability": "mutable", "name": "operator", "nameLocation": "4472:8:4", "nodeType": "VariableDeclaration", "scope": 6641, "src": "4464:16:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 6635, "name": "address", "nodeType": "ElementaryTypeName", "src": "4464:7:4", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "visibility": "internal" }, { "constant": false, "id": 6638, "mutability": "mutable", "name": "_approved", "nameLocation": "4487:9:4", "nodeType": "VariableDeclaration", "scope": 6641, "src": "4482:14:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" }, "typeName": { "id": 6637, "name": "bool", "nodeType": "ElementaryTypeName", "src": "4482:4:4", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "visibility": "internal" } ], "src": "4463:34:4" }, "returnParameters": { "id": 6640, "nodeType": "ParameterList", "parameters": [], "src": "4506:0:4" }, "scope": 6660, "src": "4437:70:4", "stateMutability": "nonpayable", "virtual": false, "visibility": "external" }, { "documentation": { "id": 6642, "nodeType": "StructuredDocumentation", "src": "4513:139:4", "text": " @dev Returns the account approved for `tokenId` token.\n Requirements:\n - `tokenId` must exist." }, "functionSelector": "081812fc", "id": 6649, "implemented": false, "kind": "function", "modifiers": [], "name": "getApproved", "nameLocation": "4666:11:4", "nodeType": "FunctionDefinition", "parameters": { "id": 6645, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 6644, "mutability": "mutable", "name": "tokenId", "nameLocation": "4686:7:4", "nodeType": "VariableDeclaration", "scope": 6649, "src": "4678:15:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256",