@etherisc/gif-contracts
Version:
This repository holds the GIF core contracts and tools to develop, test and deploy GIF instances.
930 lines • 30.1 kB
JSON
{
"abi": [
{
"inputs": [
{
"internalType": "bytes32",
"name": "role",
"type": "bytes32"
}
],
"name": "addRole",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [],
"name": "getDefaultAdminRole",
"outputs": [
{
"internalType": "bytes32",
"name": "role",
"type": "bytes32"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "getOracleProviderRole",
"outputs": [
{
"internalType": "bytes32",
"name": "role",
"type": "bytes32"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "getProductOwnerRole",
"outputs": [
{
"internalType": "bytes32",
"name": "role",
"type": "bytes32"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "getRiskpoolKeeperRole",
"outputs": [
{
"internalType": "bytes32",
"name": "role",
"type": "bytes32"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "bytes32",
"name": "role",
"type": "bytes32"
},
{
"internalType": "address",
"name": "principal",
"type": "address"
}
],
"name": "grantRole",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "bytes32",
"name": "role",
"type": "bytes32"
},
{
"internalType": "address",
"name": "principal",
"type": "address"
}
],
"name": "hasRole",
"outputs": [
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "bytes32",
"name": "role",
"type": "bytes32"
}
],
"name": "invalidateRole",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "bytes32",
"name": "role",
"type": "bytes32"
},
{
"internalType": "address",
"name": "principal",
"type": "address"
}
],
"name": "renounceRole",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "bytes32",
"name": "role",
"type": "bytes32"
},
{
"internalType": "address",
"name": "principal",
"type": "address"
}
],
"name": "revokeRole",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
}
],
"allSourcePaths": {
"37": "/home/vscode/.brownie/packages/etherisc/gif-interface@3b0002a/contracts/modules/IAccess.sol"
},
"ast": {
"absolutePath": "/home/vscode/.brownie/packages/etherisc/gif-interface@3b0002a/contracts/modules/IAccess.sol",
"exportedSymbols": {
"IAccess": [
21938
]
},
"id": 21939,
"license": "Apache-2.0",
"nodeType": "SourceUnit",
"nodes": [
{
"id": 21877,
"literals": [
"solidity",
"0.8",
".2"
],
"nodeType": "PragmaDirective",
"src": "39:22:37"
},
{
"abstract": false,
"baseContracts": [],
"contractDependencies": [],
"contractKind": "interface",
"fullyImplemented": false,
"id": 21938,
"linearizedBaseContracts": [
21938
],
"name": "IAccess",
"nameLocation": "73:7:37",
"nodeType": "ContractDefinition",
"nodes": [
{
"functionSelector": "52a9c8d7",
"id": 21882,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "getDefaultAdminRole",
"nameLocation": "96:19:37",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 21878,
"nodeType": "ParameterList",
"parameters": [],
"src": "115:2:37"
},
"returnParameters": {
"id": 21881,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 21880,
"mutability": "mutable",
"name": "role",
"nameLocation": "148:4:37",
"nodeType": "VariableDeclaration",
"scope": 21882,
"src": "140:12:37",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
},
"typeName": {
"id": 21879,
"name": "bytes32",
"nodeType": "ElementaryTypeName",
"src": "140:7:37",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"visibility": "internal"
}
],
"src": "139:14:37"
},
"scope": 21938,
"src": "87:67:37",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"functionSelector": "775a4048",
"id": 21887,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "getProductOwnerRole",
"nameLocation": "168:19:37",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 21883,
"nodeType": "ParameterList",
"parameters": [],
"src": "187:2:37"
},
"returnParameters": {
"id": 21886,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 21885,
"mutability": "mutable",
"name": "role",
"nameLocation": "220:4:37",
"nodeType": "VariableDeclaration",
"scope": 21887,
"src": "212:12:37",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
},
"typeName": {
"id": 21884,
"name": "bytes32",
"nodeType": "ElementaryTypeName",
"src": "212:7:37",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"visibility": "internal"
}
],
"src": "211:14:37"
},
"scope": 21938,
"src": "159:67:37",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"functionSelector": "d49d21c0",
"id": 21892,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "getOracleProviderRole",
"nameLocation": "240:21:37",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 21888,
"nodeType": "ParameterList",
"parameters": [],
"src": "261:2:37"
},
"returnParameters": {
"id": 21891,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 21890,
"mutability": "mutable",
"name": "role",
"nameLocation": "294:4:37",
"nodeType": "VariableDeclaration",
"scope": 21892,
"src": "286:12:37",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
},
"typeName": {
"id": 21889,
"name": "bytes32",
"nodeType": "ElementaryTypeName",
"src": "286:7:37",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"visibility": "internal"
}
],
"src": "285:14:37"
},
"scope": 21938,
"src": "231:69:37",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"functionSelector": "3ffdd2f3",
"id": 21897,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "getRiskpoolKeeperRole",
"nameLocation": "314:21:37",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 21893,
"nodeType": "ParameterList",
"parameters": [],
"src": "335:2:37"
},
"returnParameters": {
"id": 21896,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 21895,
"mutability": "mutable",
"name": "role",
"nameLocation": "368:4:37",
"nodeType": "VariableDeclaration",
"scope": 21897,
"src": "360:12:37",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
},
"typeName": {
"id": 21894,
"name": "bytes32",
"nodeType": "ElementaryTypeName",
"src": "360:7:37",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"visibility": "internal"
}
],
"src": "359:14:37"
},
"scope": 21938,
"src": "305:69:37",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"functionSelector": "91d14854",
"id": 21906,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "hasRole",
"nameLocation": "388:7:37",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 21902,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 21899,
"mutability": "mutable",
"name": "role",
"nameLocation": "404:4:37",
"nodeType": "VariableDeclaration",
"scope": 21906,
"src": "396:12:37",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
},
"typeName": {
"id": 21898,
"name": "bytes32",
"nodeType": "ElementaryTypeName",
"src": "396:7:37",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"visibility": "internal"
},
{
"constant": false,
"id": 21901,
"mutability": "mutable",
"name": "principal",
"nameLocation": "418:9:37",
"nodeType": "VariableDeclaration",
"scope": 21906,
"src": "410:17:37",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 21900,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "410:7:37",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"visibility": "internal"
}
],
"src": "395:33:37"
},
"returnParameters": {
"id": 21905,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 21904,
"mutability": "mutable",
"name": "",
"nameLocation": "-1:-1:-1",
"nodeType": "VariableDeclaration",
"scope": 21906,
"src": "451:4:37",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 21903,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "451:4:37",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"visibility": "internal"
}
],
"src": "450:6:37"
},
"scope": 21938,
"src": "379:78:37",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"functionSelector": "2f2ff15d",
"id": 21913,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "grantRole",
"nameLocation": "472:9:37",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 21911,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 21908,
"mutability": "mutable",
"name": "role",
"nameLocation": "490:4:37",
"nodeType": "VariableDeclaration",
"scope": 21913,
"src": "482:12:37",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
},
"typeName": {
"id": 21907,
"name": "bytes32",
"nodeType": "ElementaryTypeName",
"src": "482:7:37",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"visibility": "internal"
},
{
"constant": false,
"id": 21910,
"mutability": "mutable",
"name": "principal",
"nameLocation": "504:9:37",
"nodeType": "VariableDeclaration",
"scope": 21913,
"src": "496:17:37",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 21909,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "496:7:37",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"visibility": "internal"
}
],
"src": "481:33:37"
},
"returnParameters": {
"id": 21912,
"nodeType": "ParameterList",
"parameters": [],
"src": "523:0:37"
},
"scope": 21938,
"src": "463:61:37",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"functionSelector": "d547741f",
"id": 21920,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "revokeRole",
"nameLocation": "538:10:37",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 21918,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 21915,
"mutability": "mutable",
"name": "role",
"nameLocation": "557:4:37",
"nodeType": "VariableDeclaration",
"scope": 21920,
"src": "549:12:37",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
},
"typeName": {
"id": 21914,
"name": "bytes32",
"nodeType": "ElementaryTypeName",
"src": "549:7:37",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"visibility": "internal"
},
{
"constant": false,
"id": 21917,
"mutability": "mutable",
"name": "principal",
"nameLocation": "571:9:37",
"nodeType": "VariableDeclaration",
"scope": 21920,
"src": "563:17:37",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 21916,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "563:7:37",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"visibility": "internal"
}
],
"src": "548:33:37"
},
"returnParameters": {
"id": 21919,
"nodeType": "ParameterList",
"parameters": [],
"src": "590:0:37"
},
"scope": 21938,
"src": "529:62:37",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"functionSelector": "36568abe",
"id": 21927,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "renounceRole",
"nameLocation": "605:12:37",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 21925,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 21922,
"mutability": "mutable",
"name": "role",
"nameLocation": "626:4:37",
"nodeType": "VariableDeclaration",
"scope": 21927,
"src": "618:12:37",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
},
"typeName": {
"id": 21921,
"name": "bytes32",
"nodeType": "ElementaryTypeName",
"src": "618:7:37",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"visibility": "internal"
},
{
"constant": false,
"id": 21924,
"mutability": "mutable",
"name": "principal",
"nameLocation": "640:9:37",
"nodeType": "VariableDeclaration",
"scope": 21927,
"src": "632:17:37",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 21923,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "632:7:37",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"visibility": "internal"
}
],
"src": "617:33:37"
},
"returnParameters": {
"id": 21926,
"nodeType": "ParameterList",
"parameters": [],
"src": "659:0:37"
},
"scope": 21938,
"src": "596:64:37",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"functionSelector": "274b02a7",
"id": 21932,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "addRole",
"nameLocation": "679:7:37",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 21930,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 21929,
"mutability": "mutable",
"name": "role",
"nameLocation": "695:4:37",
"nodeType": "VariableDeclaration",
"scope": 21932,
"src": "687:12:37",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
},
"typeName": {
"id": 21928,
"name": "bytes32",
"nodeType": "ElementaryTypeName",
"src": "687:7:37",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"visibility": "internal"
}
],
"src": "686:14:37"
},
"returnParameters": {
"id": 21931,
"nodeType": "ParameterList",
"parameters": [],
"src": "709:0:37"
},
"scope": 21938,
"src": "670:40:37",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"functionSelector": "d17d0233",
"id": 21937,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "invalidateRole",
"nameLocation": "724:14:37",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 21935,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 21934,
"mutability": "mutable",
"name": "role",
"nameLocation": "747:4:37",
"nodeType": "VariableDeclaration",
"scope": 21937,
"src": "739:12:37",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
},
"typeName": {
"id": 21933,
"name": "bytes32",
"nodeType": "ElementaryTypeName",
"src": "739:7:37",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"visibility": "internal"
}
],
"src": "738:14:37"
},
"returnParameters": {
"id": 21936,
"nodeType": "ParameterList",
"parameters": [],
"src": "761:0:37"
},
"scope": 21938,
"src": "715:47:37",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
}
],
"scope": 21939,
"src": "63:701:37"
}
],
"src": "39:726:37"
},
"bytecode": "",
"bytecodeSha1": "da39a3ee5e6b4b0d3255bfef95601890afd80709",
"compiler": {
"evm_version": "istanbul",
"optimizer": {
"enabled": true,
"runs": 200
},
"version": "0.8.2+commit.661d1103"
},
"contractName": "IAccess",
"coverageMap": {
"branches": {},
"statements": {}
},
"dependencies": [],
"deployedBytecode": "",
"deployedSourceMap": "",
"language": "Solidity",
"natspec": {
"kind": "dev",
"methods": {},
"version": 1
},
"offset": [
63,
764
],
"opcodes": "",
"pcMap": {},
"sha1": "a627854a98fb7c354fa37ef6c8d43b90735ce377",
"source": "// SPDX-License-Identifier: Apache-2.0\npragma solidity 0.8.2;\n\ninterface IAccess {\n function getDefaultAdminRole() external view returns(bytes32 role);\n function getProductOwnerRole() external view returns(bytes32 role);\n function getOracleProviderRole() external view returns(bytes32 role);\n function getRiskpoolKeeperRole() external view returns(bytes32 role);\n function hasRole(bytes32 role, address principal) external view returns(bool);\n\n function grantRole(bytes32 role, address principal) external;\n function revokeRole(bytes32 role, address principal) external;\n function renounceRole(bytes32 role, address principal) external;\n \n function addRole(bytes32 role) external;\n function invalidateRole(bytes32 role) external;\n}\n",
"sourceMap": "",
"sourcePath": "/home/vscode/.brownie/packages/etherisc/gif-interface@3b0002a/contracts/modules/IAccess.sol",
"type": "interface"
}