UNPKG

@etherisc/depeg-contracts

Version:

Etherisc's smart contracts for a depeg insurance for stable coins.

1,457 lines (1,456 loc) 66.1 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": { "15": "/home/vscode/.brownie/packages/OpenZeppelin/openzeppelin-contracts@4.7.3/contracts/utils/introspection/IERC165.sol", "7": "/home/vscode/.brownie/packages/OpenZeppelin/openzeppelin-contracts@4.7.3/contracts/token/ERC721/IERC721.sol" }, "ast": { "absolutePath": "/home/vscode/.brownie/packages/OpenZeppelin/openzeppelin-contracts@4.7.3/contracts/token/ERC721/IERC721.sol", "exportedSymbols": { "IERC165": [ 22864 ], "IERC721": [ 13932 ] }, "id": 13933, "license": "MIT", "nodeType": "SourceUnit", "nodes": [ { "id": 13818, "literals": [ "solidity", "^", "0.8", ".0" ], "nodeType": "PragmaDirective", "src": "108:23:7" }, { "absolutePath": "/home/vscode/.brownie/packages/OpenZeppelin/openzeppelin-contracts@4.7.3/contracts/utils/introspection/IERC165.sol", "file": "../../utils/introspection/IERC165.sol", "id": 13819, "nameLocation": "-1:-1:-1", "nodeType": "ImportDirective", "scope": 13933, "sourceUnit": 22865, "src": "133:47:7", "symbolAliases": [], "unitAlias": "" }, { "abstract": false, "baseContracts": [ { "baseName": { "id": 13821, "name": "IERC165", "nodeType": "IdentifierPath", "referencedDeclaration": 22864, "src": "271:7:7" }, "id": 13822, "nodeType": "InheritanceSpecifier", "src": "271:7:7" } ], "contractDependencies": [ 22864 ], "contractKind": "interface", "documentation": { "id": 13820, "nodeType": "StructuredDocumentation", "src": "182:67:7", "text": " @dev Required interface of an ERC721 compliant contract." }, "fullyImplemented": false, "id": 13932, "linearizedBaseContracts": [ 13932, 22864 ], "name": "IERC721", "nameLocation": "260:7:7", "nodeType": "ContractDefinition", "nodes": [ { "anonymous": false, "documentation": { "id": 13823, "nodeType": "StructuredDocumentation", "src": "285:88:7", "text": " @dev Emitted when `tokenId` token is transferred from `from` to `to`." }, "id": 13831, "name": "Transfer", "nameLocation": "384:8:7", "nodeType": "EventDefinition", "parameters": { "id": 13830, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 13825, "indexed": true, "mutability": "mutable", "name": "from", "nameLocation": "409:4:7", "nodeType": "VariableDeclaration", "scope": 13831, "src": "393:20:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 13824, "name": "address", "nodeType": "ElementaryTypeName", "src": "393:7:7", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "visibility": "internal" }, { "constant": false, "id": 13827, "indexed": true, "mutability": "mutable", "name": "to", "nameLocation": "431:2:7", "nodeType": "VariableDeclaration", "scope": 13831, "src": "415:18:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 13826, "name": "address", "nodeType": "ElementaryTypeName", "src": "415:7:7", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "visibility": "internal" }, { "constant": false, "id": 13829, "indexed": true, "mutability": "mutable", "name": "tokenId", "nameLocation": "451:7:7", "nodeType": "VariableDeclaration", "scope": 13831, "src": "435:23:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 13828, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "435:7:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "visibility": "internal" } ], "src": "392:67:7" }, "src": "378:82:7" }, { "anonymous": false, "documentation": { "id": 13832, "nodeType": "StructuredDocumentation", "src": "466:94:7", "text": " @dev Emitted when `owner` enables `approved` to manage the `tokenId` token." }, "id": 13840, "name": "Approval", "nameLocation": "571:8:7", "nodeType": "EventDefinition", "parameters": { "id": 13839, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 13834, "indexed": true, "mutability": "mutable", "name": "owner", "nameLocation": "596:5:7", "nodeType": "VariableDeclaration", "scope": 13840, "src": "580:21:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 13833, "name": "address", "nodeType": "ElementaryTypeName", "src": "580:7:7", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "visibility": "internal" }, { "constant": false, "id": 13836, "indexed": true, "mutability": "mutable", "name": "approved", "nameLocation": "619:8:7", "nodeType": "VariableDeclaration", "scope": 13840, "src": "603:24:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 13835, "name": "address", "nodeType": "ElementaryTypeName", "src": "603:7:7", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "visibility": "internal" }, { "constant": false, "id": 13838, "indexed": true, "mutability": "mutable", "name": "tokenId", "nameLocation": "645:7:7", "nodeType": "VariableDeclaration", "scope": 13840, "src": "629:23:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 13837, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "629:7:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "visibility": "internal" } ], "src": "579:74:7" }, "src": "565:89:7" }, { "anonymous": false, "documentation": { "id": 13841, "nodeType": "StructuredDocumentation", "src": "660:117:7", "text": " @dev Emitted when `owner` enables or disables (`approved`) `operator` to manage all of its assets." }, "id": 13849, "name": "ApprovalForAll", "nameLocation": "788:14:7", "nodeType": "EventDefinition", "parameters": { "id": 13848, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 13843, "indexed": true, "mutability": "mutable", "name": "owner", "nameLocation": "819:5:7", "nodeType": "VariableDeclaration", "scope": 13849, "src": "803:21:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 13842, "name": "address", "nodeType": "ElementaryTypeName", "src": "803:7:7", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "visibility": "internal" }, { "constant": false, "id": 13845, "indexed": true, "mutability": "mutable", "name": "operator", "nameLocation": "842:8:7", "nodeType": "VariableDeclaration", "scope": 13849, "src": "826:24:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 13844, "name": "address", "nodeType": "ElementaryTypeName", "src": "826:7:7", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "visibility": "internal" }, { "constant": false, "id": 13847, "indexed": false, "mutability": "mutable", "name": "approved", "nameLocation": "857:8:7", "nodeType": "VariableDeclaration", "scope": 13849, "src": "852:13:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" }, "typeName": { "id": 13846, "name": "bool", "nodeType": "ElementaryTypeName", "src": "852:4:7", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "visibility": "internal" } ], "src": "802:64:7" }, "src": "782:85:7" }, { "documentation": { "id": 13850, "nodeType": "StructuredDocumentation", "src": "873:76:7", "text": " @dev Returns the number of tokens in ``owner``'s account." }, "functionSelector": "70a08231", "id": 13857, "implemented": false, "kind": "function", "modifiers": [], "name": "balanceOf", "nameLocation": "963:9:7", "nodeType": "FunctionDefinition", "parameters": { "id": 13853, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 13852, "mutability": "mutable", "name": "owner", "nameLocation": "981:5:7", "nodeType": "VariableDeclaration", "scope": 13857, "src": "973:13:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 13851, "name": "address", "nodeType": "ElementaryTypeName", "src": "973:7:7", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "visibility": "internal" } ], "src": "972:15:7" }, "returnParameters": { "id": 13856, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 13855, "mutability": "mutable", "name": "balance", "nameLocation": "1019:7:7", "nodeType": "VariableDeclaration", "scope": 13857, "src": "1011:15:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 13854, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "1011:7:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "visibility": "internal" } ], "src": "1010:17:7" }, "scope": 13932, "src": "954:74:7", "stateMutability": "view", "virtual": false, "visibility": "external" }, { "documentation": { "id": 13858, "nodeType": "StructuredDocumentation", "src": "1034:131:7", "text": " @dev Returns the owner of the `tokenId` token.\n Requirements:\n - `tokenId` must exist." }, "functionSelector": "6352211e", "id": 13865, "implemented": false, "kind": "function", "modifiers": [], "name": "ownerOf", "nameLocation": "1179:7:7", "nodeType": "FunctionDefinition", "parameters": { "id": 13861, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 13860, "mutability": "mutable", "name": "tokenId", "nameLocation": "1195:7:7", "nodeType": "VariableDeclaration", "scope": 13865, "src": "1187:15:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 13859, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "1187:7:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "visibility": "internal" } ], "src": "1186:17:7" }, "returnParameters": { "id": 13864, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 13863, "mutability": "mutable", "name": "owner", "nameLocation": "1235:5:7", "nodeType": "VariableDeclaration", "scope": 13865, "src": "1227:13:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 13862, "name": "address", "nodeType": "ElementaryTypeName", "src": "1227:7:7", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "visibility": "internal" } ], "src": "1226:15:7" }, "scope": 13932, "src": "1170:72:7", "stateMutability": "view", "virtual": false, "visibility": "external" }, { "documentation": { "id": 13866, "nodeType": "StructuredDocumentation", "src": "1248:556:7", "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": 13877, "implemented": false, "kind": "function", "modifiers": [], "name": "safeTransferFrom", "nameLocation": "1818:16:7", "nodeType": "FunctionDefinition", "parameters": { "id": 13875, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 13868, "mutability": "mutable", "name": "from", "nameLocation": "1852:4:7", "nodeType": "VariableDeclaration", "scope": 13877, "src": "1844:12:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 13867, "name": "address", "nodeType": "ElementaryTypeName", "src": "1844:7:7", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "visibility": "internal" }, { "constant": false, "id": 13870, "mutability": "mutable", "name": "to", "nameLocation": "1874:2:7", "nodeType": "VariableDeclaration", "scope": 13877, "src": "1866:10:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 13869, "name": "address", "nodeType": "ElementaryTypeName", "src": "1866:7:7", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "visibility": "internal" }, { "constant": false, "id": 13872, "mutability": "mutable", "name": "tokenId", "nameLocation": "1894:7:7", "nodeType": "VariableDeclaration", "scope": 13877, "src": "1886:15:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 13871, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "1886:7:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "visibility": "internal" }, { "constant": false, "id": 13874, "mutability": "mutable", "name": "data", "nameLocation": "1926:4:7", "nodeType": "VariableDeclaration", "scope": 13877, "src": "1911:19:7", "stateVariable": false, "storageLocation": "calldata", "typeDescriptions": { "typeIdentifier": "t_bytes_calldata_ptr", "typeString": "bytes" }, "typeName": { "id": 13873, "name": "bytes", "nodeType": "ElementaryTypeName", "src": "1911:5:7", "typeDescriptions": { "typeIdentifier": "t_bytes_storage_ptr", "typeString": "bytes" } }, "visibility": "internal" } ], "src": "1834:102:7" }, "returnParameters": { "id": 13876, "nodeType": "ParameterList", "parameters": [], "src": "1945:0:7" }, "scope": 13932, "src": "1809:137:7", "stateMutability": "nonpayable", "virtual": false, "visibility": "external" }, { "documentation": { "id": 13878, "nodeType": "StructuredDocumentation", "src": "1952:687:7", "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": 13887, "implemented": false, "kind": "function", "modifiers": [], "name": "safeTransferFrom", "nameLocation": "2653:16:7", "nodeType": "FunctionDefinition", "parameters": { "id": 13885, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 13880, "mutability": "mutable", "name": "from", "nameLocation": "2687:4:7", "nodeType": "VariableDeclaration", "scope": 13887, "src": "2679:12:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 13879, "name": "address", "nodeType": "ElementaryTypeName", "src": "2679:7:7", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "visibility": "internal" }, { "constant": false, "id": 13882, "mutability": "mutable", "name": "to", "nameLocation": "2709:2:7", "nodeType": "VariableDeclaration", "scope": 13887, "src": "2701:10:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 13881, "name": "address", "nodeType": "ElementaryTypeName", "src": "2701:7:7", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "visibility": "internal" }, { "constant": false, "id": 13884, "mutability": "mutable", "name": "tokenId", "nameLocation": "2729:7:7", "nodeType": "VariableDeclaration", "scope": 13887, "src": "2721:15:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 13883, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "2721:7:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "visibility": "internal" } ], "src": "2669:73:7" }, "returnParameters": { "id": 13886, "nodeType": "ParameterList", "parameters": [], "src": "2751:0:7" }, "scope": 13932, "src": "2644:108:7", "stateMutability": "nonpayable", "virtual": false, "visibility": "external" }, { "documentation": { "id": 13888, "nodeType": "StructuredDocumentation", "src": "2758:504:7", "text": " @dev Transfers `tokenId` token from `from` to `to`.\n WARNING: Usage of this method is discouraged, use {safeTransferFrom} whenever possible.\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": 13897, "implemented": false, "kind": "function", "modifiers": [], "name": "transferFrom", "nameLocation": "3276:12:7", "nodeType": "FunctionDefinition", "parameters": { "id": 13895, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 13890, "mutability": "mutable", "name": "from", "nameLocation": "3306:4:7", "nodeType": "VariableDeclaration", "scope": 13897, "src": "3298:12:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 13889, "name": "address", "nodeType": "ElementaryTypeName", "src": "3298:7:7", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "visibility": "internal" }, { "constant": false, "id": 13892, "mutability": "mutable", "name": "to", "nameLocation": "3328:2:7", "nodeType": "VariableDeclaration", "scope": 13897, "src": "3320:10:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 13891, "name": "address", "nodeType": "ElementaryTypeName", "src": "3320:7:7", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "visibility": "internal" }, { "constant": false, "id": 13894, "mutability": "mutable", "name": "tokenId", "nameLocation": "3348:7:7", "nodeType": "VariableDeclaration", "scope": 13897, "src": "3340:15:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 13893, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "3340:7:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "visibility": "internal" } ], "src": "3288:73:7" }, "returnParameters": { "id": 13896, "nodeType": "ParameterList", "parameters": [], "src": "3370:0:7" }, "scope": 13932, "src": "3267:104:7", "stateMutability": "nonpayable", "virtual": false, "visibility": "external" }, { "documentation": { "id": 13898, "nodeType": "StructuredDocumentation", "src": "3377:452:7", "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": 13905, "implemented": false, "kind": "function", "modifiers": [], "name": "approve", "nameLocation": "3843:7:7", "nodeType": "FunctionDefinition", "parameters": { "id": 13903, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 13900, "mutability": "mutable", "name": "to", "nameLocation": "3859:2:7", "nodeType": "VariableDeclaration", "scope": 13905, "src": "3851:10:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 13899, "name": "address", "nodeType": "ElementaryTypeName", "src": "3851:7:7", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "visibility": "internal" }, { "constant": false, "id": 13902, "mutability": "mutable", "name": "tokenId", "nameLocation": "3871:7:7", "nodeType": "VariableDeclaration", "scope": 13905, "src": "3863:15:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 13901, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "3863:7:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "visibility": "internal" } ], "src": "3850:29:7" }, "returnParameters": { "id": 13904, "nodeType": "ParameterList", "parameters": [], "src": "3888:0:7" }, "scope": 13932, "src": "3834:55:7", "stateMutability": "nonpayable", "virtual": false, "visibility": "external" }, { "documentation": { "id": 13906, "nodeType": "StructuredDocumentation", "src": "3895:309:7", "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": 13913, "implemented": false, "kind": "function", "modifiers": [], "name": "setApprovalForAll", "nameLocation": "4218:17:7", "nodeType": "FunctionDefinition", "parameters": { "id": 13911, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 13908, "mutability": "mutable", "name": "operator", "nameLocation": "4244:8:7", "nodeType": "VariableDeclaration", "scope": 13913, "src": "4236:16:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 13907, "name": "address", "nodeType": "ElementaryTypeName", "src": "4236:7:7", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "visibility": "internal" }, { "constant": false, "id": 13910, "mutability": "mutable", "name": "_approved", "nameLocation": "4259:9:7", "nodeType": "VariableDeclaration", "scope": 13913, "src": "4254:14:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" }, "typeName": { "id": 13909, "name": "bool", "nodeType": "ElementaryTypeName", "src": "4254:4:7", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "visibility": "internal" } ], "src": "4235:34:7" }, "returnParameters": { "id": 13912, "nodeType": "ParameterList", "parameters": [], "src": "4278:0:7" }, "scope": 13932, "src": "4209:70:7", "stateMutability": "nonpayable", "virtual": false, "visibility": "external" }, { "documentation": { "id": 13914, "nodeType": "StructuredDocumentation", "src": "4285:139:7", "text": " @dev Returns the account approved for `tokenId` token.\n Requirements:\n - `tokenId` must exist." }, "functionSelector": "081812fc", "id": 13921, "implemented": false, "kind": "function", "modifiers": [], "name": "getApproved", "nameLocation": "4438:11:7", "nodeType": "FunctionDefinition", "parameters": { "id": 13917, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 13916, "mutability": "mutable", "name": "tokenId", "nameLocation": "4458:7:7", "nodeType": "VariableDeclaration", "scope": 13921, "src": "4450:15:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" },