UNPKG

witnet-solidity-bridge

Version:

Witnet Solidity Bridge contracts for EVM-compatible chains

1,177 lines 70.5 kB
{ "contractName": "WitnetRequestBytecodesData", "abi": [], "metadata": "{\"compiler\":{\"version\":\"0.8.25+commit.b61c2a91\"},\"language\":\"Solidity\",\"output\":{\"abi\":[],\"devdoc\":{\"author\":\"The Witnet Foundation.\",\"kind\":\"dev\",\"methods\":{},\"title\":\"Witnet Request Board base data model. \",\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"project:/contracts/data/WitnetRequestBytecodesData.sol\":\"WitnetRequestBytecodesData\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":true,\"runs\":200},\"remappings\":[]},\"sources\":{\"project:/contracts/data/WitnetRequestBytecodesData.sol\":{\"keccak256\":\"0xfe7cab06f3999216c6db1a280a85370a17cb51d9e487052ab8d18547661d55d4\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://b53c61a3476416c420658b04b7e1a77c2e634e469ea3837dcbbcb86c17ea2cb2\",\"dweb:/ipfs/QmcBRZPfAcqk4zq5VrPH38hvYhYx7wJUgmAiYrKqLyn8JX\"]},\"project:/contracts/libs/Witnet.sol\":{\"keccak256\":\"0x65a87375dd79d63a83fb454b7199b6c999bd59c50b3b59d521c5c4d45a7d3cc3\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://ca865b681d810c2fc5c3672ea6343c3bdf6fd71764ab824d25994744dc85866b\",\"dweb:/ipfs/QmPGcP3xGTNZfsQ9GSKdujNLRVs8dWDdubyUko1rbQqJNv\"]},\"project:/contracts/libs/WitnetBuffer.sol\":{\"keccak256\":\"0xa14570492eb5a313ddbacae0185c850ec99c67211eb33989a5e21d31bf06a150\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://e83c11edb49cab6a767c0b685825bc22ece0d3d2897e0d54fe1923df5cc76ba5\",\"dweb:/ipfs/QmdLDgCc3tnKbgRrXwfNzsg6uUDirNmjvBB8V3iMmnD69a\"]},\"project:/contracts/libs/WitnetCBOR.sol\":{\"keccak256\":\"0xb346547ff731163beea2c657c52675cdf7936691d566a76a045577cf9c34ade0\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://6d4b5b6424a033584b41f1204d635db98fda9ca9bd2a614c9d82539a3e4e6529\",\"dweb:/ipfs/QmW6Qy3wWpzHSECYaCPaf9LWGfPqWDKVoP2kPSNNQu7LMQ\"]},\"project:/contracts/libs/WitnetV2.sol\":{\"keccak256\":\"0xb276a6da373bfbe9cd942dd7e59979cda898215d1e36ab3df95a6d6cc6ff770f\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://bc4890876b9bc64f501ccdd48408bb63724865cb2ce8d2057f6b318540adce7c\",\"dweb:/ipfs/QmPMHPdbCsKBavhiLcaDgQ9EjNSvwwzv8TKffotcCv1ctP\"]}},\"version\":1}", "bytecode": "0x", "deployedBytecode": "0x", "immutableReferences": {}, "generatedSources": [], "deployedGeneratedSources": [], "sourceMap": "", "deployedSourceMap": "", "source": "// SPDX-License-Identifier: MIT\r\n\r\npragma solidity >=0.8.0 <0.9.0;\r\n\r\nimport \"../libs/WitnetV2.sol\";\r\n\r\n/// @title Witnet Request Board base data model. \r\n/// @author The Witnet Foundation.\r\nabstract contract WitnetRequestBytecodesData {\r\n \r\n bytes32 private constant _WITNET_BYTECODES_DATA_SLOTHASH =\r\n /* keccak256(\"io.witnet.bytecodes.data\") */\r\n 0x673359bdfd0124f9962355e7aed2d07d989b0d4bc4cbe2c94c295e0f81427dec;\r\n\r\n struct Storage {\r\n address base;\r\n address owner;\r\n address pendingOwner;\r\n \r\n Database db;\r\n uint256 totalDataProviders;\r\n // ...\r\n }\r\n\r\n struct DataProvider {\r\n string authority;\r\n uint256 totalEndpoints;\r\n mapping (uint256 => bytes32) endpoints;\r\n }\r\n\r\n struct DataRequest {\r\n string[][] args;\r\n bytes32 aggregator;\r\n bytes32 radHash;\r\n Witnet.RadonDataTypes resultDataType;\r\n uint16 resultMaxSize;\r\n bytes32[] retrievals;\r\n bytes32 tally;\r\n }\r\n\r\n struct Database {\r\n mapping (uint256 => DataProvider) providers;\r\n mapping (bytes32 => uint256) providersIndex;\r\n \r\n mapping (bytes32 => Witnet.RadonReducer) reducers;\r\n mapping (bytes32 => Witnet.RadonRetrieval) retrievals;\r\n mapping (bytes32 => DataRequest) requests;\r\n mapping (bytes32 => bytes32) rads;\r\n mapping (bytes32 => bytes) radsBytecode;\r\n mapping (bytes32 => bytes) _slasBytecode;\r\n }\r\n\r\n constructor() {\r\n // auto-initialize upon deployment\r\n __bytecodes().base = address(this);\r\n }\r\n\r\n\r\n // ================================================================================================================\r\n // --- Internal state-modifying functions -------------------------------------------------------------------------\r\n \r\n /// @dev Returns storage pointer to contents of 'Storage' struct.\r\n function __bytecodes()\r\n internal pure\r\n returns (Storage storage _ptr)\r\n {\r\n assembly {\r\n _ptr.slot := _WITNET_BYTECODES_DATA_SLOTHASH\r\n }\r\n }\r\n\r\n /// @dev Returns storage pointer to contents of 'Database' struct.\r\n function __database()\r\n internal view\r\n returns (Database storage _ptr)\r\n {\r\n return __bytecodes().db;\r\n }\r\n\r\n function __requests(bytes32 _radHash)\r\n internal view\r\n returns (DataRequest storage _ptr)\r\n {\r\n return __database().requests[_radHash];\r\n }\r\n}", "sourcePath": "C:\\Users\\guill\\github\\witnet\\witnet-solidity-bridge\\contracts\\data\\WitnetRequestBytecodesData.sol", "ast": { "absolutePath": "project:/contracts/data/WitnetRequestBytecodesData.sol", "exportedSymbols": { "Witnet": [ 17557 ], "WitnetBuffer": [ 19191 ], "WitnetCBOR": [ 20734 ], "WitnetRequestBytecodesData": [ 12657 ], "WitnetV2": [ 23640 ] }, "id": 12658, "license": "MIT", "nodeType": "SourceUnit", "nodes": [ { "id": 12525, "literals": [ "solidity", ">=", "0.8", ".0", "<", "0.9", ".0" ], "nodeType": "PragmaDirective", "src": "35:31:43" }, { "absolutePath": "project:/contracts/libs/WitnetV2.sol", "file": "../libs/WitnetV2.sol", "id": 12526, "nameLocation": "-1:-1:-1", "nodeType": "ImportDirective", "scope": 12658, "sourceUnit": 23641, "src": "70:30:43", "symbolAliases": [], "unitAlias": "" }, { "abstract": true, "baseContracts": [], "canonicalName": "WitnetRequestBytecodesData", "contractDependencies": [], "contractKind": "contract", "documentation": { "id": 12527, "nodeType": "StructuredDocumentation", "src": "104:87:43", "text": "@title Witnet Request Board base data model. \n @author The Witnet Foundation." }, "fullyImplemented": true, "id": 12657, "linearizedBaseContracts": [ 12657 ], "name": "WitnetRequestBytecodesData", "nameLocation": "209:26:43", "nodeType": "ContractDefinition", "nodes": [ { "constant": true, "id": 12530, "mutability": "constant", "name": "_WITNET_BYTECODES_DATA_SLOTHASH", "nameLocation": "274:31:43", "nodeType": "VariableDeclaration", "scope": 12657, "src": "249:187:43", "stateVariable": true, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_bytes32", "typeString": "bytes32" }, "typeName": { "id": 12528, "name": "bytes32", "nodeType": "ElementaryTypeName", "src": "249:7:43", "typeDescriptions": { "typeIdentifier": "t_bytes32", "typeString": "bytes32" } }, "value": { "hexValue": "307836373333353962646664303132346639393632333535653761656432643037643938396230643462633463626532633934633239356530663831343237646563", "id": 12529, "isConstant": false, "isLValue": false, "isPure": true, "kind": "number", "lValueRequested": false, "nodeType": "Literal", "src": "370:66:43", "typeDescriptions": { "typeIdentifier": "t_rational_46678951981879400639642737301436337472165334789432541772196806227380807040492_by_1", "typeString": "int_const 4667...(69 digits omitted)...0492" }, "value": "0x673359bdfd0124f9962355e7aed2d07d989b0d4bc4cbe2c94c295e0f81427dec" }, "visibility": "private" }, { "canonicalName": "WitnetRequestBytecodesData.Storage", "id": 12542, "members": [ { "constant": false, "id": 12532, "mutability": "mutable", "name": "base", "nameLocation": "479:4:43", "nodeType": "VariableDeclaration", "scope": 12542, "src": "471:12:43", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 12531, "name": "address", "nodeType": "ElementaryTypeName", "src": "471:7:43", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "visibility": "internal" }, { "constant": false, "id": 12534, "mutability": "mutable", "name": "owner", "nameLocation": "502:5:43", "nodeType": "VariableDeclaration", "scope": 12542, "src": "494:13:43", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 12533, "name": "address", "nodeType": "ElementaryTypeName", "src": "494:7:43", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "visibility": "internal" }, { "constant": false, "id": 12536, "mutability": "mutable", "name": "pendingOwner", "nameLocation": "526:12:43", "nodeType": "VariableDeclaration", "scope": 12542, "src": "518:20:43", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 12535, "name": "address", "nodeType": "ElementaryTypeName", "src": "518:7:43", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "visibility": "internal" }, { "constant": false, "id": 12539, "mutability": "mutable", "name": "db", "nameLocation": "568:2:43", "nodeType": "VariableDeclaration", "scope": 12542, "src": "559:11:43", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_struct$_Database_$12607_storage_ptr", "typeString": "struct WitnetRequestBytecodesData.Database" }, "typeName": { "id": 12538, "nodeType": "UserDefinedTypeName", "pathNode": { "id": 12537, "name": "Database", "nameLocations": [ "559:8:43" ], "nodeType": "IdentifierPath", "referencedDeclaration": 12607, "src": "559:8:43" }, "referencedDeclaration": 12607, "src": "559:8:43", "typeDescriptions": { "typeIdentifier": "t_struct$_Database_$12607_storage_ptr", "typeString": "struct WitnetRequestBytecodesData.Database" } }, "visibility": "internal" }, { "constant": false, "id": 12541, "mutability": "mutable", "name": "totalDataProviders", "nameLocation": "589:18:43", "nodeType": "VariableDeclaration", "scope": 12542, "src": "581:26:43", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 12540, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "581:7:43", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "visibility": "internal" } ], "name": "Storage", "nameLocation": "452:7:43", "nodeType": "StructDefinition", "scope": 12657, "src": "445:186:43", "visibility": "public" }, { "canonicalName": "WitnetRequestBytecodesData.DataProvider", "id": 12551, "members": [ { "constant": false, "id": 12544, "mutability": "mutable", "name": "authority", "nameLocation": "678:9:43", "nodeType": "VariableDeclaration", "scope": 12551, "src": "670:17:43", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_string_storage_ptr", "typeString": "string" }, "typeName": { "id": 12543, "name": "string", "nodeType": "ElementaryTypeName", "src": "670:6:43", "typeDescriptions": { "typeIdentifier": "t_string_storage_ptr", "typeString": "string" } }, "visibility": "internal" }, { "constant": false, "id": 12546, "mutability": "mutable", "name": "totalEndpoints", "nameLocation": "706:14:43", "nodeType": "VariableDeclaration", "scope": 12551, "src": "698:22:43", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 12545, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "698:7:43", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "visibility": "internal" }, { "constant": false, "id": 12550, "mutability": "mutable", "name": "endpoints", "nameLocation": "760:9:43", "nodeType": "VariableDeclaration", "scope": 12551, "src": "731:38:43", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_uint256_$_t_bytes32_$", "typeString": "mapping(uint256 => bytes32)" }, "typeName": { "id": 12549, "keyName": "", "keyNameLocation": "-1:-1:-1", "keyType": { "id": 12547, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "740:7:43", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "Mapping", "src": "731:28:43", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_uint256_$_t_bytes32_$", "typeString": "mapping(uint256 => bytes32)" }, "valueName": "", "valueNameLocation": "-1:-1:-1", "valueType": { "id": 12548, "name": "bytes32", "nodeType": "ElementaryTypeName", "src": "751:7:43", "typeDescriptions": { "typeIdentifier": "t_bytes32", "typeString": "bytes32" } } }, "visibility": "internal" } ], "name": "DataProvider", "nameLocation": "646:12:43", "nodeType": "StructDefinition", "scope": 12657, "src": "639:138:43", "visibility": "public" }, { "canonicalName": "WitnetRequestBytecodesData.DataRequest", "id": 12570, "members": [ { "constant": false, "id": 12555, "mutability": "mutable", "name": "args", "nameLocation": "826:4:43", "nodeType": "VariableDeclaration", "scope": 12570, "src": "815:15:43", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_array$_t_array$_t_string_storage_$dyn_storage_$dyn_storage_ptr", "typeString": "string[][]" }, "typeName": { "baseType": { "baseType": { "id": 12552, "name": "string", "nodeType": "ElementaryTypeName", "src": "815:6:43", "typeDescriptions": { "typeIdentifier": "t_string_storage_ptr", "typeString": "string" } }, "id": 12553, "nodeType": "ArrayTypeName", "src": "815:8:43", "typeDescriptions": { "typeIdentifier": "t_array$_t_string_storage_$dyn_storage_ptr", "typeString": "string[]" } }, "id": 12554, "nodeType": "ArrayTypeName", "src": "815:10:43", "typeDescriptions": { "typeIdentifier": "t_array$_t_array$_t_string_storage_$dyn_storage_$dyn_storage_ptr", "typeString": "string[][]" } }, "visibility": "internal" }, { "constant": false, "id": 12557, "mutability": "mutable", "name": "aggregator", "nameLocation": "849:10:43", "nodeType": "VariableDeclaration", "scope": 12570, "src": "841:18:43", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_bytes32", "typeString": "bytes32" }, "typeName": { "id": 12556, "name": "bytes32", "nodeType": "ElementaryTypeName", "src": "841:7:43", "typeDescriptions": { "typeIdentifier": "t_bytes32", "typeString": "bytes32" } }, "visibility": "internal" }, { "constant": false, "id": 12559, "mutability": "mutable", "name": "radHash", "nameLocation": "878:7:43", "nodeType": "VariableDeclaration", "scope": 12570, "src": "870:15:43", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_bytes32", "typeString": "bytes32" }, "typeName": { "id": 12558, "name": "bytes32", "nodeType": "ElementaryTypeName", "src": "870:7:43", "typeDescriptions": { "typeIdentifier": "t_bytes32", "typeString": "bytes32" } }, "visibility": "internal" }, { "constant": false, "id": 12562, "mutability": "mutable", "name": "resultDataType", "nameLocation": "918:14:43", "nodeType": "VariableDeclaration", "scope": 12570, "src": "896:36:43", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_enum$_RadonDataTypes_$16432", "typeString": "enum Witnet.RadonDataTypes" }, "typeName": { "id": 12561, "nodeType": "UserDefinedTypeName", "pathNode": { "id": 12560, "name": "Witnet.RadonDataTypes", "nameLocations": [ "896:6:43", "903:14:43" ], "nodeType": "IdentifierPath", "referencedDeclaration": 16432, "src": "896:21:43" }, "referencedDeclaration": 16432, "src": "896:21:43", "typeDescriptions": { "typeIdentifier": "t_enum$_RadonDataTypes_$16432", "typeString": "enum Witnet.RadonDataTypes" } }, "visibility": "internal" }, { "constant": false, "id": 12564, "mutability": "mutable", "name": "resultMaxSize", "nameLocation": "950:13:43", "nodeType": "VariableDeclaration", "scope": 12570, "src": "943:20:43", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint16", "typeString": "uint16" }, "typeName": { "id": 12563, "name": "uint16", "nodeType": "ElementaryTypeName", "src": "943:6:43", "typeDescriptions": { "typeIdentifier": "t_uint16", "typeString": "uint16" } }, "visibility": "internal" }, { "constant": false, "id": 12567, "mutability": "mutable", "name": "retrievals", "nameLocation": "984:10:43", "nodeType": "VariableDeclaration", "scope": 12570, "src": "974:20:43", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_array$_t_bytes32_$dyn_storage_ptr", "typeString": "bytes32[]" }, "typeName": { "baseType": { "id": 12565, "name": "bytes32", "nodeType": "ElementaryTypeName", "src": "974:7:43", "typeDescriptions": { "typeIdentifier": "t_bytes32", "typeString": "bytes32" } }, "id": 12566, "nodeType": "ArrayTypeName", "src": "974:9:43", "typeDescriptions": { "typeIdentifier": "t_array$_t_bytes32_$dyn_storage_ptr", "typeString": "bytes32[]" } }, "visibility": "internal" }, { "constant": false, "id": 12569, "mutability": "mutable", "name": "tally", "nameLocation": "1013:5:43", "nodeType": "VariableDeclaration", "scope": 12570, "src": "1005:13:43", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_bytes32", "typeString": "bytes32" }, "typeName": { "id": 12568, "name": "bytes32", "nodeType": "ElementaryTypeName", "src": "1005:7:43", "typeDescriptions": { "typeIdentifier": "t_bytes32", "typeString": "bytes32" } }, "visibility": "internal" } ], "name": "DataRequest", "nameLocation": "792:11:43", "nodeType": "StructDefinition", "scope": 12657, "src": "785:241:43", "visibility": "public" }, { "canonicalName": "WitnetRequestBytecodesData.Database", "id": 12607, "members": [ { "constant": false, "id": 12575, "mutability": "mutable", "name": "providers", "nameLocation": "1095:9:43", "nodeType": "VariableDeclaration", "scope": 12607, "src": "1061:43:43", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_uint256_$_t_struct$_DataProvider_$12551_storage_$", "typeString": "mapping(uint256 => struct WitnetRequestBytecodesData.DataProvider)" }, "typeName": { "id": 12574, "keyName": "", "keyNameLocation": "-1:-1:-1", "keyType": { "id": 12571, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "1070:7:43", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "Mapping", "src": "1061:33:43", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_uint256_$_t_struct$_DataProvider_$12551_storage_$", "typeString": "mapping(uint256 => struct WitnetRequestBytecodesData.DataProvider)" }, "valueName": "", "valueNameLocation": "-1:-1:-1", "valueType": { "id": 12573, "nodeType": "UserDefinedTypeName", "pathNode": { "id": 12572, "name": "DataProvider", "nameLocations": [ "1081:12:43" ], "nodeType": "IdentifierPath", "referencedDeclaration": 12551, "src": "1081:12:43" }, "referencedDeclaration": 12551, "src": "1081:12:43", "typeDescriptions": { "typeIdentifier": "t_struct$_DataProvider_$12551_storage_ptr", "typeString": "struct WitnetRequestBytecodesData.DataProvider" } } }, "visibility": "internal" }, { "constant": false, "id": 12579, "mutability": "mutable", "name": "providersIndex", "nameLocation": "1144:14:43", "nodeType": "VariableDeclaration", "scope": 12607, "src": "1115:43:43", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_bytes32_$_t_uint256_$", "typeString": "mapping(bytes32 => uint256)" }, "typeName": { "id": 12578, "keyName": "", "keyNameLocation": "-1:-1:-1", "keyType": { "id": 12576, "name": "bytes32", "nodeType": "ElementaryTypeName", "src": "1124:7:43", "typeDescriptions": { "typeIdentifier": "t_bytes32", "typeString": "bytes32" } }, "nodeType": "Mapping", "src": "1115:28:43", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_bytes32_$_t_uint256_$", "typeString": "mapping(bytes32 => uint256)" }, "valueName": "", "valueNameLocation": "-1:-1:-1", "valueType": { "id": 12577, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "1135:7:43", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } }, "visibility": "internal" }, { "constant": false, "id": 12584, "mutability": "mutable", "name": "reducers", "nameLocation": "1220:8:43", "nodeType": "VariableDeclaration", "scope": 12607, "src": "1179:49:43", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_bytes32_$_t_struct$_RadonReducer_$16460_storage_$", "typeString": "mapping(bytes32 => struct Witnet.RadonReducer)" }, "typeName": { "id": 12583, "keyName": "", "keyNameLocation": "-1:-1:-1", "keyType": { "id": 12580, "name": "bytes32", "nodeType": "ElementaryTypeName", "src": "1188:7:43", "typeDescriptions": { "typeIdentifier": "t_bytes32", "typeString": "bytes32" } }, "nodeType": "Mapping", "src": "1179:40:43", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_bytes32_$_t_struct$_RadonReducer_$16460_storage_$", "typeString": "mapping(bytes32 => struct Witnet.RadonReducer)" }, "valueName": "", "valueNameLocation": "-1:-1:-1", "valueType": { "id": 12582, "nodeType": "UserDefinedTypeName", "pathNode": { "id": 12581, "name": "Witnet.RadonReducer", "nameLocations": [ "1199:6:43", "1206:12:43" ], "nodeType": "IdentifierPath", "referencedDeclaration": 16460, "src": "1199:19:43" }, "referencedDeclaration": 16460, "src": "1199:19:43", "typeDescriptions": { "typeIdentifier": "t_struct$_RadonReducer_$16460_storage_ptr", "typeString": "struct Witnet.RadonReducer" } } }, "visibility": "internal" }, { "constant": false, "id": 12589, "mutability": "mutable", "name": "retrievals", "nameLocation": "1282:10:43", "nodeType": "VariableDeclaration", "scope": 12607, "src": "1239:53:43", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_bytes32_$_t_struct$_RadonRetrieval_$16495_storage_$", "typeString": "mapping(bytes32 => struct Witnet.RadonRetrieval)" }, "typeName": { "id": 12588, "keyName": "", "keyNameLocation": "-1:-1:-1", "keyType": { "id": 12585, "name": "bytes32", "nodeType": "ElementaryTypeName", "src": "1248:7:43", "typeDescriptions": { "typeIdentifier": "t_bytes32", "typeString": "bytes32" } }, "nodeType": "Mapping", "src": "1239:42:43", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_bytes32_$_t_struct$_RadonRetrieval_$16495_storage_$", "typeString": "mapping(bytes32 => struct Witnet.RadonRetrieval)" }, "valueName": "", "valueNameLocation": "-1:-1:-1", "valueType": { "id": 12587, "nodeType": "UserDefinedTypeName", "pathNode": { "id": 12586, "name": "Witnet.RadonRetrieval", "nameLocations": [ "1259:6:43", "1266:14:43" ], "nodeType": "IdentifierPath", "referencedDeclaration": 16495, "src": "1259:21:43" }, "referencedDeclaration": 16495, "src": "1259:21:43", "typeDescriptions": { "typeIdentifier": "t_struct$_RadonRetrieval_$16495_storage_ptr", "typeString": "struct Witnet.RadonRetrieval" } } }, "visibility": "internal" }, { "constant": false, "id": 12594, "mutability": "mutable", "name": "requests", "nameLocation": "1336:8:43", "nodeType": "VariableDeclaration", "scope": 12607, "src": "1303:41:43", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_bytes32_$_t_struct$_DataRequest_$12570_storage_$", "typeString": "mapping(bytes32 => struct WitnetRequestBytecodesData.DataRequest)" }, "typeName": { "id": 12593, "keyName": "", "keyNameLocation": "-1:-1:-1", "keyType": { "id": 12590, "name": "bytes32", "nodeType": "ElementaryTypeName", "src": "1312:7:43", "typeDescriptions": { "typeIdentifier": "t_bytes32", "typeString": "bytes32" } }, "nodeType": "Mapping", "src": "1303:32:43", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_bytes32_$_t_struct$_DataRequest_$12570_storage_$", "typeString": "mapping(bytes32 => struct WitnetRequestBytecodesData.DataRequest)" }, "valueName": "", "valueNameLocation": "-1:-1:-1", "valueType": { "id": 12592, "nodeType": "UserDefinedTypeName", "pathNode": { "id": 12591, "name": "DataRequest", "nameLocations": [ "1323:11:43" ], "nodeType": "IdentifierPath", "referencedDeclaration": 12570, "src": "1323:11:43" }, "referencedDeclaration": 12570, "src": "1323:11:43", "typeDescriptions": { "typeIdentifier": "t_struct$_DataRequest_$12570_storage_ptr", "typeString": "struct WitnetRequestBytecodesData.DataRequest" } } }, "visibility": "internal" }, { "constant": false, "id": 12598, "mutability": "mutable", "name": "rads", "nameLocation": "1384:4:43", "nodeType": "VariableDeclaration", "scope": 12607, "src": "1355:33:43", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_bytes32_$_t_bytes32_$", "typeString": "mapping(bytes32 => bytes32)" }, "typeName": { "id": 12597, "keyName": "", "keyNameLocation": "-1:-1:-1", "keyType": { "id": 12595, "name": "bytes32", "nodeType": "ElementaryTypeName", "src": "1364:7:43", "typeDescriptions": { "typeIdentifier": "t_bytes32", "typeString": "bytes32" } }, "nodeType": "Mapping", "src": "1355:28:43", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_bytes32_$_t_bytes32_$", "typeString": "mapping(bytes32 => bytes32)" }, "valueName": "", "valueNameLocation": "-1:-1:-1", "valueType": { "id": 12596, "name": "bytes32", "nodeType": "ElementaryTypeName", "src": "1375:7:43", "typeDescriptions": { "typeIdentifier": "t_bytes32", "typeString": "bytes32" } } }, "visibility": "internal" }, { "constant": false, "id": 12602, "mutability": "mutable", "name": "radsBytecode", "nameLocation": "1426:12:43", "nodeType": "VariableDeclaration", "scope": 12607, "src": "1399:39:43", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_bytes32_$_t_bytes_storage_$", "typeString": "mapping(bytes32 => bytes)" }, "typeName": { "id": 12601, "keyName": "", "keyNameLocation": "-1:-1:-1", "keyType": { "id": 12599, "name": "bytes32", "nodeType": "ElementaryTypeName", "src": "1408:7:43", "typeDescriptions": { "typeIdentifier": "t_bytes32", "typeString": "bytes32" } }, "nodeType": "Mapping", "src": "1399:26:43", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_bytes32_$_t_bytes_storage_$", "typeString": "mapping(bytes32 => bytes)" }, "valueName": "", "valueNameLocation": "-1:-1:-1", "valueType": { "id": 12600, "name": "bytes", "nodeType": "ElementaryTypeName", "src": "1419:5:43", "typeDescriptions": { "typeIdentifier": "t_bytes_storage_ptr", "typeString": "bytes" } } }, "visibility": "internal" }, { "constant": false, "id": 12606, "mutability": "mutable", "name": "_slasBytecode", "nameLocation": "1476:13:43", "nodeType": "VariableDeclaration", "scope": 12607, "src": "1449:40:43", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_bytes32_$_t_bytes_storage_$", "typeString": "mapping(bytes32 => bytes)" }, "typeName": { "id": 12605, "keyName": "", "keyNameLocation": "-1:-1:-1", "keyType": { "id": 12603, "name": "bytes32", "nodeType": "ElementaryTypeName", "src": "1458:7:43", "typeDescriptions": { "typeIdentifier": "t_bytes32", "typeString": "bytes32" } }, "nodeType": "Mapping", "src": "1449:26:43", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_bytes32_$_t_bytes_storage_$", "typeString": "mapping(bytes32 => bytes)" }, "valueName": "", "valueNameLocation": "-1:-1:-1", "valueType": { "id": 12604, "name": "bytes", "nodeType": "ElementaryTypeName", "src": "1469:5:43", "typeDescriptions": { "typeIdentifier": "t_bytes_storage_ptr", "typeString": "bytes" } } }, "visibility": "internal" } ], "name": "Database", "nameLocation": "1041:8:43", "nodeType": "StructDefinition", "scope": 12657, "src": "1034:463:43", "visibility": "public" }, { "body": { "id": 12619, "nodeType": "Block", "src": "1519:97:43", "statements": [ { "expression": { "id": 12617, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "expression": { "arguments": [], "expression": { "argumentTypes": [], "id": 12610, "name": "__bytecodes", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 12629, "src": "1574:11:43", "typeDescriptions": { "typeIdentifier": "t_function_internal_pure$__$returns$_t_struct$_Storage_$12542_storage_ptr_$", "typeString": "function () pure returns (struct WitnetRequestBytecodesData.Storage storage pointer)" } }, "id": 12611, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "nameLocations": [], "names": [], "nodeType": "FunctionCall", "src": "1574:13:43", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_struct$_Storage_$12542_storage_ptr", "typeString": "struct WitnetRequestBytecodesData.Storage storage pointer" } }, "id": 12612, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": true, "memberLocation": "1588:4:43", "memberName": "base", "nodeType": "MemberAccess", "referencedDeclaration": 12532, "src": "1574:18:43", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "nodeType": "Assignment", "operator": "=", "rightHandSide": { "arguments": [ { "id": 12615, "name": "this", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 4294967268, "src": "1603:4:43", "typeDescriptions": { "typeIdentifier": "t_contract$_WitnetRequestBytecodesData_$12657", "typeString": "contract WitnetRequestBytecodesData" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_contract$_WitnetRequestBytecodesData_$12657", "typeString": "contract WitnetRequestBytecodesDat