@zjbtest/contracts
Version:
AcalaNetwork Smart Contract library for Solidity
297 lines • 9.92 kB
JSON
{
"contractName": "IOracle",
"abi": [
{
"inputs": [
{
"internalType": "address",
"name": "token",
"type": "address"
}
],
"name": "getPrice",
"outputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
}
],
"metadata": "{\"compiler\":{\"version\":\"0.8.0+commit.c7dfd78e\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"token\",\"type\":\"address\"}],\"name\":\"getPrice\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"}],\"devdoc\":{\"kind\":\"dev\",\"methods\":{},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"/home/runner/work/predeploy-contracts/predeploy-contracts/contracts/oracle/IOracle.sol\":\"IOracle\"},\"evmVersion\":\"istanbul\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/home/runner/work/predeploy-contracts/predeploy-contracts/contracts/oracle/IOracle.sol\":{\"keccak256\":\"0x9ee6c9eeb31d554e9dbd373d00ebc851338cd3f929cbecdead114d8c9c37d80a\",\"license\":\"GPL-3.0-or-later\",\"urls\":[\"bzz-raw://aa50be779cea5de6aa3bff6e0868cf7ee3379773d7893d5b8f2a6697718ca3ac\",\"dweb:/ipfs/QmXFEyXihcWcroD8VLUCVBiQBSxn1HvjTvBM6Tsva3PJyS\"]}},\"version\":1}",
"bytecode": "0x",
"deployedBytecode": "0x",
"immutableReferences": {},
"generatedSources": [],
"deployedGeneratedSources": [],
"sourceMap": "",
"deployedSourceMap": "",
"source": "// SPDX-License-Identifier: GPL-3.0-or-later\n\npragma solidity ^0.8.0;\n\ninterface IOracle {\n // Get the price of the currency_id.\n // Returns the price.\n function getPrice(address token) external view returns (uint256);\n}\n",
"sourcePath": "/home/runner/work/predeploy-contracts/predeploy-contracts/contracts/oracle/IOracle.sol",
"ast": {
"absolutePath": "/home/runner/work/predeploy-contracts/predeploy-contracts/contracts/oracle/IOracle.sol",
"exportedSymbols": {
"IOracle": [
822
]
},
"id": 823,
"license": "GPL-3.0-or-later",
"nodeType": "SourceUnit",
"nodes": [
{
"id": 814,
"literals": [
"solidity",
"^",
"0.8",
".0"
],
"nodeType": "PragmaDirective",
"src": "46:23:3"
},
{
"abstract": false,
"baseContracts": [],
"contractDependencies": [],
"contractKind": "interface",
"fullyImplemented": false,
"id": 822,
"linearizedBaseContracts": [
822
],
"name": "IOracle",
"nodeType": "ContractDefinition",
"nodes": [
{
"functionSelector": "41976e09",
"id": 821,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "getPrice",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 817,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 816,
"mutability": "mutable",
"name": "token",
"nodeType": "VariableDeclaration",
"scope": 821,
"src": "180:13:3",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 815,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "180:7:3",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"visibility": "internal"
}
],
"src": "179:15:3"
},
"returnParameters": {
"id": 820,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 819,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"scope": 821,
"src": "218:7:3",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 818,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "218:7:3",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"visibility": "internal"
}
],
"src": "217:9:3"
},
"scope": 822,
"src": "162:65:3",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
}
],
"scope": 823,
"src": "71:158:3"
}
],
"src": "46:184:3"
},
"legacyAST": {
"absolutePath": "/home/runner/work/predeploy-contracts/predeploy-contracts/contracts/oracle/IOracle.sol",
"exportedSymbols": {
"IOracle": [
822
]
},
"id": 823,
"license": "GPL-3.0-or-later",
"nodeType": "SourceUnit",
"nodes": [
{
"id": 814,
"literals": [
"solidity",
"^",
"0.8",
".0"
],
"nodeType": "PragmaDirective",
"src": "46:23:3"
},
{
"abstract": false,
"baseContracts": [],
"contractDependencies": [],
"contractKind": "interface",
"fullyImplemented": false,
"id": 822,
"linearizedBaseContracts": [
822
],
"name": "IOracle",
"nodeType": "ContractDefinition",
"nodes": [
{
"functionSelector": "41976e09",
"id": 821,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "getPrice",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 817,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 816,
"mutability": "mutable",
"name": "token",
"nodeType": "VariableDeclaration",
"scope": 821,
"src": "180:13:3",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 815,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "180:7:3",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"visibility": "internal"
}
],
"src": "179:15:3"
},
"returnParameters": {
"id": 820,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 819,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"scope": 821,
"src": "218:7:3",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 818,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "218:7:3",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"visibility": "internal"
}
],
"src": "217:9:3"
},
"scope": 822,
"src": "162:65:3",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
}
],
"scope": 823,
"src": "71:158:3"
}
],
"src": "46:184:3"
},
"compiler": {
"name": "solc",
"version": "0.8.0+commit.c7dfd78e.Emscripten.clang"
},
"networks": {},
"schemaVersion": "3.3.1",
"updatedAt": "2021-11-23T02:17:24.045Z",
"devdoc": {
"kind": "dev",
"methods": {},
"version": 1
},
"userdoc": {
"kind": "user",
"methods": {},
"version": 1
}
}