UNPKG

@etherisc/terraguard-poc-contracts

Version:

Etherisc's smart contracts for the terraguard poc

1,628 lines 346 kB
{ "abi": [ { "inputs": [ { "internalType": "bytes32", "name": "oracleName", "type": "bytes32" }, { "internalType": "address", "name": "registry", "type": "address" } ], "stateMutability": "nonpayable", "type": "constructor" }, { "anonymous": false, "inputs": [ { "indexed": false, "internalType": "uint256", "name": "id", "type": "uint256" } ], "name": "LogComponentApproved", "type": "event" }, { "anonymous": false, "inputs": [ { "indexed": false, "internalType": "uint256", "name": "id", "type": "uint256" } ], "name": "LogComponentArchived", "type": "event" }, { "anonymous": false, "inputs": [ { "indexed": false, "internalType": "bytes32", "name": "componentName", "type": "bytes32" }, { "indexed": false, "internalType": "enum IComponent.ComponentType", "name": "componentType", "type": "uint8" }, { "indexed": false, "internalType": "address", "name": "componentAddress", "type": "address" }, { "indexed": false, "internalType": "address", "name": "registryAddress", "type": "address" } ], "name": "LogComponentCreated", "type": "event" }, { "anonymous": false, "inputs": [ { "indexed": false, "internalType": "uint256", "name": "id", "type": "uint256" } ], "name": "LogComponentDeclined", "type": "event" }, { "anonymous": false, "inputs": [ { "indexed": false, "internalType": "uint256", "name": "id", "type": "uint256" } ], "name": "LogComponentPaused", "type": "event" }, { "anonymous": false, "inputs": [ { "indexed": false, "internalType": "bytes32", "name": "componentName", "type": "bytes32" }, { "indexed": false, "internalType": "enum IComponent.ComponentType", "name": "componentType", "type": "uint8" }, { "indexed": false, "internalType": "address", "name": "componentAddress", "type": "address" }, { "indexed": false, "internalType": "uint256", "name": "id", "type": "uint256" } ], "name": "LogComponentProposed", "type": "event" }, { "anonymous": false, "inputs": [ { "indexed": false, "internalType": "uint256", "name": "id", "type": "uint256" } ], "name": "LogComponentResumed", "type": "event" }, { "anonymous": false, "inputs": [ { "indexed": false, "internalType": "uint256", "name": "id", "type": "uint256" }, { "indexed": false, "internalType": "enum IComponent.ComponentState", "name": "stateOld", "type": "uint8" }, { "indexed": false, "internalType": "enum IComponent.ComponentState", "name": "stateNew", "type": "uint8" } ], "name": "LogComponentStateChanged", "type": "event" }, { "anonymous": false, "inputs": [ { "indexed": false, "internalType": "uint256", "name": "id", "type": "uint256" } ], "name": "LogComponentSuspended", "type": "event" }, { "anonymous": false, "inputs": [ { "indexed": false, "internalType": "uint256", "name": "id", "type": "uint256" } ], "name": "LogComponentUnpaused", "type": "event" }, { "anonymous": false, "inputs": [ { "indexed": false, "internalType": "uint256", "name": "requestId", "type": "uint256" }, { "indexed": false, "internalType": "string", "name": "objectName", "type": "string" } ], "name": "LogFireOracleRequest", "type": "event" }, { "anonymous": false, "inputs": [ { "indexed": false, "internalType": "uint256", "name": "componentId", "type": "uint256" } ], "name": "LogOracleApproved", "type": "event" }, { "anonymous": false, "inputs": [ { "indexed": false, "internalType": "address", "name": "oracleAddress", "type": "address" } ], "name": "LogOracleCreated", "type": "event" }, { "anonymous": false, "inputs": [ { "indexed": false, "internalType": "uint256", "name": "componentId", "type": "uint256" } ], "name": "LogOracleDeclined", "type": "event" }, { "anonymous": false, "inputs": [ { "indexed": false, "internalType": "uint256", "name": "componentId", "type": "uint256" } ], "name": "LogOracleProposed", "type": "event" }, { "anonymous": false, "inputs": [ { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } ], "name": "OwnershipTransferred", "type": "event" }, { "inputs": [], "name": "approvalCallback", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [], "name": "archiveCallback", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [ { "internalType": "uint256", "name": "requestId", "type": "uint256" } ], "name": "cancel", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [], "name": "declineCallback", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [], "name": "getId", "outputs": [ { "internalType": "uint256", "name": "", "type": "uint256" } ], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "getName", "outputs": [ { "internalType": "bytes32", "name": "", "type": "bytes32" } ], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "getOwner", "outputs": [ { "internalType": "address", "name": "", "type": "address" } ], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "getRegistry", "outputs": [ { "internalType": "contract IRegistry", "name": "", "type": "address" } ], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "getState", "outputs": [ { "internalType": "enum IComponent.ComponentState", "name": "", "type": "uint8" } ], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "getType", "outputs": [ { "internalType": "enum IComponent.ComponentType", "name": "", "type": "uint8" } ], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "isOracle", "outputs": [ { "internalType": "bool", "name": "", "type": "bool" } ], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "isProduct", "outputs": [ { "internalType": "bool", "name": "", "type": "bool" } ], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "isRiskpool", "outputs": [ { "internalType": "bool", "name": "", "type": "bool" } ], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "owner", "outputs": [ { "internalType": "address", "name": "", "type": "address" } ], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "pauseCallback", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [], "name": "proposalCallback", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [ { "internalType": "uint256", "name": "requestId", "type": "uint256" }, { "internalType": "bytes", "name": "input", "type": "bytes" } ], "name": "request", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [ { "internalType": "string", "name": "objectName", "type": "string" } ], "name": "requestId", "outputs": [ { "internalType": "uint256", "name": "", "type": "uint256" } ], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "requestIds", "outputs": [ { "internalType": "uint256", "name": "", "type": "uint256" } ], "stateMutability": "view", "type": "function" }, { "inputs": [ { "internalType": "uint256", "name": "requestId", "type": "uint256" }, { "internalType": "bytes1", "name": "fireCategory", "type": "bytes1" } ], "name": "respond", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [], "name": "resumeCallback", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [ { "internalType": "uint256", "name": "id", "type": "uint256" } ], "name": "setId", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [], "name": "suspendCallback", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [ { "internalType": "address", "name": "newOwner", "type": "address" } ], "name": "transferOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [], "name": "unpauseCallback", "outputs": [], "stateMutability": "nonpayable", "type": "function" } ], "allSourcePaths": { "0": "/home/runner/.brownie/packages/OpenZeppelin/openzeppelin-contracts@4.8.2/contracts/access/Ownable.sol", "10": "/home/runner/.brownie/packages/etherisc/gif-interface@3b0002a/contracts/components/IOracle.sol", "13": "/home/runner/.brownie/packages/etherisc/gif-interface@3b0002a/contracts/components/Oracle.sol", "16": "/home/runner/.brownie/packages/etherisc/gif-interface@3b0002a/contracts/modules/IAccess.sol", "18": "/home/runner/.brownie/packages/etherisc/gif-interface@3b0002a/contracts/modules/IComponentEvents.sol", "2": "/home/runner/.brownie/packages/OpenZeppelin/openzeppelin-contracts@4.8.2/contracts/token/ERC20/IERC20.sol", "21": "/home/runner/.brownie/packages/etherisc/gif-interface@3b0002a/contracts/modules/IRegistry.sol", "23": "/home/runner/.brownie/packages/etherisc/gif-interface@3b0002a/contracts/services/IComponentOwnerService.sol", "24": "/home/runner/.brownie/packages/etherisc/gif-interface@3b0002a/contracts/services/IInstanceOperatorService.sol", "25": "/home/runner/.brownie/packages/etherisc/gif-interface@3b0002a/contracts/services/IInstanceService.sol", "26": "/home/runner/.brownie/packages/etherisc/gif-interface@3b0002a/contracts/services/IOracleService.sol", "27": "/home/runner/.brownie/packages/etherisc/gif-interface@3b0002a/contracts/services/IProductService.sol", "28": "/home/runner/.brownie/packages/etherisc/gif-interface@3b0002a/contracts/services/IRiskpoolService.sol", "29": "/home/runner/.brownie/packages/etherisc/gif-interface@3b0002a/contracts/tokens/IBundleToken.sol", "31": "contracts/fire/FireOracle.sol", "4": "/home/runner/.brownie/packages/OpenZeppelin/openzeppelin-contracts@4.8.2/contracts/token/ERC721/IERC721.sol", "5": "/home/runner/.brownie/packages/OpenZeppelin/openzeppelin-contracts@4.8.2/contracts/utils/Context.sol", "6": "/home/runner/.brownie/packages/OpenZeppelin/openzeppelin-contracts@4.8.2/contracts/utils/introspection/IERC165.sol", "8": "/home/runner/.brownie/packages/etherisc/gif-interface@3b0002a/contracts/components/Component.sol", "9": "/home/runner/.brownie/packages/etherisc/gif-interface@3b0002a/contracts/components/IComponent.sol" }, "ast": { "absolutePath": "contracts/fire/FireOracle.sol", "exportedSymbols": { "Component": [ 5114 ], "Context": [ 6682 ], "FireOracle": [ 138 ], "IAccess": [ 6858 ], "IBundle": [ 3612 ], "IBundleToken": [ 4029 ], "IComponent": [ 5218 ], "IComponentEvents": [ 6911 ], "IComponentOwnerService": [ 7044 ], "IERC165": [ 7662 ], "IERC20": [ 4694 ], "IERC721": [ 6660 ], "IInstanceOperatorService": [ 7311 ], "IInstanceService": [ 5668 ], "IOracle": [ 5252 ], "IOracleService": [ 5262 ], "IPolicy": [ 3958 ], "IPool": [ 7160 ], "IProductService": [ 5813 ], "IRegistry": [ 7009 ], "IRiskpoolService": [ 7417 ], "ITreasury": [ 2409 ], "Oracle": [ 2511 ], "Ownable": [ 6795 ] }, "id": 139, "license": "Apache-2.0", "nodeType": "SourceUnit", "nodes": [ { "id": 8, "literals": [ "solidity", "^", "0.8", ".2" ], "nodeType": "PragmaDirective", "src": "39:23:31" }, { "absolutePath": "/home/runner/.brownie/packages/etherisc/gif-interface@3b0002a/contracts/components/Oracle.sol", "file": "@etherisc/gif-interface/contracts/components/Oracle.sol", "id": 9, "nameLocation": "-1:-1:-1", "nodeType": "ImportDirective", "scope": 139, "sourceUnit": 2512, "src": "64:65:31", "symbolAliases": [], "unitAlias": "" }, { "abstract": false, "baseContracts": [ { "baseName": { "id": 10, "name": "Oracle", "nodeType": "IdentifierPath", "referencedDeclaration": 2511, "src": "154:6:31" }, "id": 11, "nodeType": "InheritanceSpecifier", "src": "154:6:31" } ], "contractDependencies": [ 2511, 5114, 5218, 5252, 6682, 6795, 6911 ], "contractKind": "contract", "fullyImplemented": true, "id": 138, "linearizedBaseContracts": [ 138, 2511, 5114, 6795, 6682, 6911, 5252, 5218 ], "name": "FireOracle", "nameLocation": "140:10:31", "nodeType": "ContractDefinition", "nodes": [ { "anonymous": false, "id": 17, "name": "LogFireOracleRequest", "nameLocation": "174:20:31", "nodeType": "EventDefinition", "parameters": { "id": 16, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 13, "indexed": false, "mutability": "mutable", "name": "requestId", "nameLocation": "212:9:31", "nodeType": "VariableDeclaration", "scope": 17, "src": "204:17:31", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 12, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "204:7:31", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "visibility": "internal" }, { "constant": false, "id": 15, "indexed": false, "mutability": "mutable", "name": "objectName", "nameLocation": "239:10:31", "nodeType": "VariableDeclaration", "scope": 17, "src": "232:17:31", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_string_memory_ptr", "typeString": "string" }, "typeName": { "id": 14, "name": "string", "nodeType": "ElementaryTypeName", "src": "232:6:31", "typeDescriptions": { "typeIdentifier": "t_string_storage_ptr", "typeString": "string" } }, "visibility": "internal" } ], "src": "194:61:31" }, "src": "168:88:31" }, { "constant": false, "id": 21, "mutability": "mutable", "name": "_requestIdMap", "nameLocation": "314:13:31", "nodeType": "VariableDeclaration", "scope": 138, "src": "262:65:31", "stateVariable": true, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_string_memory_ptr_$_t_uint256_$", "typeString": "mapping(string => uint256)" }, "typeName": { "id": 20, "keyType": { "id": 18, "name": "string", "nodeType": "ElementaryTypeName", "src": "270:6:31", "typeDescriptions": { "typeIdentifier": "t_string_storage_ptr", "typeString": "string" } }, "nodeType": "Mapping", "src": "262:43:31", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_string_memory_ptr_$_t_uint256_$", "typeString": "mapping(string => uint256)" }, "valueType": { "id": 19, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "297:7:31", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } }, "visibility": "private" }, { "constant": false, "id": 24, "mutability": "mutable", "name": "_requestIds", "nameLocation": "349:11:31", "nodeType": "VariableDeclaration", "scope": 138, "src": "333:31:31", "stateVariable": true, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 22, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "333:7:31", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": { "hexValue": "30", "id": 23, "isConstant": false, "isLValue": false, "isPure": true, "kind": "number", "lValueRequested": false, "nodeType": "Literal", "src": "363:1:31", "typeDescriptions": { "typeIdentifier": "t_rational_0_by_1", "typeString": "int_const 0" }, "value": "0" }, "visibility": "private" }, { "body": { "id": 35, "nodeType": "Block", "src": "484:3:31", "statements": [] }, "id": 36, "implemented": true, "kind": "constructor", "modifiers": [ { "arguments": [ { "id": 31, "name": "oracleName", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 26, "src": "458:10:31", "typeDescriptions": { "typeIdentifier": "t_bytes32", "typeString": "bytes32" } }, { "id": 32, "name": "registry", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 28, "src": "470:8:31", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } } ], "id": 33, "modifierName": { "id": 30, "name": "Oracle", "nodeType": "IdentifierPath", "referencedDeclaration": 2511, "src": "451:6:31" }, "nodeType": "ModifierInvocation", "src": "451:28:31" } ], "name": "", "nameLocation": "-1:-1:-1", "nodeType": "FunctionDefinition", "parameters": { "id": 29, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 26, "mutability": "mutable", "name": "oracleName", "nameLocation": "400:10:31", "nodeType": "VariableDeclaration", "scope": 36, "src": "392:18:31", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_bytes32", "typeString": "bytes32" }, "typeName": { "id": 25, "name": "bytes32", "nodeType": "ElementaryTypeName", "src": "392:7:31", "typeDescriptions": { "typeIdentifier": "t_bytes32", "typeString": "bytes32" } }, "visibility": "internal" }, { "constant": false, "id": 28, "mutability": "mutable", "name": "registry", "nameLocation": "428:8:31", "nodeType": "VariableDeclaration", "scope": 36, "src": "420:16:31", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 27, "name": "address", "nodeType": "ElementaryTypeName", "src": "420:7:31", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "visibility": "internal" } ], "src": "382:60:31" }, "returnParameters": { "id": 34, "nodeType": "ParameterList", "parameters": [], "src": "484:0:31" }, "scope": 138, "src": "371:116:31", "stateMutability": "nonpayable", "virtual": false, "visibility": "public" }, { "baseFunctions": [ 5246 ], "body": { "id": 71, "nodeType": "Block", "src": "610:240:31", "statements": [ { "assignments": [ 47 ], "declarations": [ { "constant": false, "id": 47, "mutability": "mutable", "name": "objectName", "nameLocation": "671:10:31", "nodeType": "VariableDeclaration", "scope": 71, "src": "657:24:31", "stateVariable": false, "storageLocation": "memory", "typeDescriptions": { "typeIdentifier": "t_string_memory_ptr", "typeString": "string" }, "typeName": { "id": 46, "name": "string", "nodeType": "ElementaryTypeName", "src": "657:6:31", "typeDescriptions": { "typeIdentifier": "t_string_storage_ptr", "typeString": "string" } }, "visibility": "internal" } ], "id": 55, "initialValue": { "arguments": [ { "id": 50, "name": "input", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 40, "src": "696:5:31", "typeDescriptions": { "typeIdentifier": "t_bytes_calldata_ptr", "typeString": "bytes calldata" } }, { "components": [ { "id": 52, "isConstant": false, "isLValue": false, "isPure": true, "lValueRequested": false, "nodeType": "ElementaryTypeNameExpression", "src": "704:6:31", "typeDescriptions": { "typeIdentifier": "t_type$_t_string_storage_ptr_$", "typeString": "type(string storage pointer)" }, "typeName": { "id": 51, "name": "string", "nodeType": "ElementaryTypeName", "src": "704:6:31", "typeDescriptions": {} } } ], "id": 53, "isConstant": false, "isInlineArray": false, "isLValue": false, "isPure": true, "lValueRequested": false, "nodeType": "TupleExpression", "src": "703:8:31", "typeDescriptions": { "typeIdentifier": "t_type$_t_string_storage_ptr_$", "typeString": "type(string storage pointer)" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_bytes_calldata_ptr", "typeString": "bytes calldata" }, { "typeIdentifier": "t_type$_t_string_storage_ptr_$", "typeString": "type(string storage pointer)" } ], "expression": { "id": 48, "name": "abi", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": -1, "src": "685:3:31", "typeDescriptions": { "typeIdentifier": "t_magic_abi", "typeString": "abi" } }, "id": 49, "isConstant": false, "isLValue": false, "isPure": true, "lValueRequested": false, "memberName": "decode", "nodeType": "MemberAccess", "src": "685:10:31", "typeDescriptions": { "typeIdentifier": "t_function_abidecode_pure$__$returns$__$", "typeString": "function () pure" } }, "id": 54, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "685:27:31", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_string_memory_ptr", "typeString": "string memory" } }, "nodeType": "VariableDeclarationStatement", "src": "656:56:31" }, { "expression": { "id": 60, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "baseExpression": { "id": 56, "name": "_requestIdMap", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 21, "src": "722:13:31", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_string_memory_ptr_$_t_uint256_$", "typeString": "mapping(string memory => uint256)" } }, "id": 58, "indexExpression": { "id": 57, "name": "objectName", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 47, "src": "736:10:31", "typeDescriptions": { "typeIdentifier": "t_string_memory_ptr", "typeString": "string memory" } }, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": true, "nodeType": "IndexAccess", "src": "722:25:31", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "Assignment", "operator": "=", "rightHandSide": { "id": 59, "name": "requestId", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 38, "src": "750:9:31", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "src": "722:37:31", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "id": 61, "nodeType": "ExpressionStatement", "src": "722:37:31" }, { "expression": { "id": 64, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "id": 62, "name": "_requestIds", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 24, "src": "769:11:31", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "Assignment", "operator": "+=", "rightHandSide": { "hexValue": "31", "id": 63, "isConstant": false, "isLValue": false, "isPure": true, "kind": "number", "lValueRequested": false, "nodeType": "Literal", "src": "784:1:31", "typeDescriptions": { "typeIdentifier": "t_rational_1_by_1", "typeString": "int_const 1" }, "value": "1" }, "src": "769:16:31", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "id": 65, "nodeType": "ExpressionStatement", "src": "769:16:31" }, { "eventCall": { "arguments": [ { "id": 67, "name": "requestId", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 38, "src": "821:9:31", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, { "id": 68, "name": "objectName", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 47, "src": "832:10:31", "typeDescriptions": { "typeIdentifier": "t_string_memory_ptr", "typeString": "string memory" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_uint256", "typeString": "uint256" }, { "typeIdentifier": "t_string_memory_ptr", "typeString": "string memory" } ], "id": 66, "name": "LogFireOracleRequest", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 17, "src": "800:20:31", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_uint256_$_t_string_memory_ptr_$returns$__$", "typeString": "function (uint256,string memory)" } }, "id": 69, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "800:43:31", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, "id": 70, "nodeType": "EmitStatement", "src": "795:48:31" } ] }, "functionSelector": "ffc79065", "id": 72, "implemented": true, "kind": "function", "modifiers": [ { "id": 44, "modifierName": { "id": 43, "name": "onlyQuery", "nodeType": "IdentifierPath", "referencedDeclaration": 2436, "src": "596:9:31" }, "nodeType": "ModifierInvocation", "src": "596:9:31" } ], "name": "request", "nameLocation": "502:7:31", "nodeType": "FunctionDefinition", "overrides": { "id": 42, "nodeType": "OverrideSpecifier", "overrides": [], "src": "578:8:31" }, "parameters": { "id": 41, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 38, "mutability": "mutable", "name": "requestId", "nameLocation": "518:9:31", "nodeType": "VariableDeclaration", "scope": 72, "src": "510:17:31", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 37, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "510:7:31", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "visibility": "internal" }, { "constant": false, "id": 40, "mutability": "mutable", "name": "input", "nameLocation": "544:5:31", "nodeType": "VariableDeclaration", "scope": 72, "src": "529:20:31", "stateVariable": false, "storageLocation": "calldata", "typeDescriptions": { "typeIdentifier": "t_bytes_calldata_ptr", "typeString": "bytes" }, "typeName": { "id": 39, "name": "bytes", "nodeType": "ElementaryTypeName", "src": "529:5:31", "typeDescriptions": { "typeIdentifier": "t_bytes_storage_ptr", "typeString": "bytes" } }, "visibility": "internal" } ], "src": "509:41:31" }, "returnParameters": { "id": 45, "nodeType": "ParameterList", "parameters": [], "src": "610:0:31" }, "scope": 138, "src": "493:357:31", "stateMutability": "nonpayable", "virtual": false, "visibility": "external" }, { "body": { "id": 83, "nodeType": "Block", "src": "935:49:31", "statements": [ { "expression": { "baseExpression": { "id": 79, "name": "_requestIdMap", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 21, "src": "952:13:31", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_string_memory_ptr_$_t_uint256_$", "typeString": "mapping(string memory => uint256)" } }, "id": 81, "indexExpression": { "id": 80, "name": "objectName", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 74, "src": "966:10:31", "typeDescriptions": { "typeIdentifier": "t_string_calldata_ptr", "typeString": "string calldata" } }, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", "src": "952:25:31", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "functionReturnParameters": 78, "id": 82, "nodeType": "Return", "src": "945:32:31" } ] }, "functionSelector": "2475cdd1", "id": 84, "implemented": true, "kind": "function", "modifiers": [], "name": "requestId", "nameLocation": "865:9:31", "nodeType": "FunctionDefinition", "parameters": { "id": 75, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 74, "mutability": "mutable", "name": "objectName", "nameLocation": "891:10:31", "nodeType": "VariableDeclaration", "scope": 84, "src": "875:26:31", "stateVariable": false, "storageLocation": "calldata", "typeDescriptions": { "typeIdentifier": "t_string_calldata_ptr", "typeString": "string" }, "typeName": { "id": 73, "name": "string", "nodeType": "ElementaryTypeName", "src": "875:6:31", "typeDescriptions": { "typeIdentifier": "t_string_storage_ptr", "typeString": "string" } }, "visibility": "internal" } ], "src": "874:28:31" }, "returnParameters": { "id": 78, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 77, "mutability": "mutable", "name": "", "nameLocation": "-1:-1:-1", "nodeType": "VariableDeclaration", "scope": 84, "src": "926:7:31", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 76, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "926:7:31", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "visibility": "internal" } ], "src": "925:9:31" }, "scope": 138, "src": "856:128:31", "stateMutability": "view", "virtual": false, "visibility": "external" }, { "body": { "id": 91, "nodeType": "Block", "src": "1044:35:31", "statements": [ { "expression": { "id": 89, "name": "_requestIds", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 24, "src": "1061:11:31", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "functio