@dolomite-exchange/dolomite-margin
Version:
Ethereum Smart Contracts and TypeScript library used for the DolomiteMargin trading protocol
1,179 lines (1,178 loc) • 126 kB
JSON
{
"contractName": "Ownable",
"abi": [
{
"inputs": [],
"payable": false,
"stateMutability": "nonpayable",
"type": "constructor"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "address",
"name": "previousOwner",
"type": "address"
},
{
"indexed": true,
"internalType": "address",
"name": "newOwner",
"type": "address"
}
],
"name": "OwnershipTransferred",
"type": "event"
},
{
"constant": true,
"inputs": [],
"name": "owner",
"outputs": [
{
"internalType": "address",
"name": "",
"type": "address"
}
],
"payable": false,
"stateMutability": "view",
"type": "function"
},
{
"constant": true,
"inputs": [],
"name": "isOwner",
"outputs": [
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"payable": false,
"stateMutability": "view",
"type": "function"
},
{
"constant": false,
"inputs": [],
"name": "renounceOwnership",
"outputs": [],
"payable": false,
"stateMutability": "nonpayable",
"type": "function"
},
{
"constant": false,
"inputs": [
{
"internalType": "address",
"name": "newOwner",
"type": "address"
}
],
"name": "transferOwnership",
"outputs": [],
"payable": false,
"stateMutability": "nonpayable",
"type": "function"
}
],
"metadata": "{\"compiler\":{\"version\":\"0.5.16+commit.9c3226ce\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"previousOwner\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"OwnershipTransferred\",\"type\":\"event\"},{\"constant\":true,\"inputs\":[],\"name\":\"isOwner\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[],\"name\":\"renounceOwnership\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"}],\"devdoc\":{\"details\":\"Contract module which provides a basic access control mechanism, where there is an account (an owner) that can be granted exclusive access to specific functions. * This module is used through inheritance. It will make available the modifier `onlyOwner`, which can be applied to your functions to restrict their use to the owner.\",\"methods\":{\"constructor\":{\"details\":\"Initializes the contract setting the deployer as the initial owner.\"},\"isOwner()\":{\"details\":\"Returns true if the caller is the current owner.\"},\"owner()\":{\"details\":\"Returns the address of the current owner.\"},\"renounceOwnership()\":{\"details\":\"Leaves the contract without owner. It will not be possible to call `onlyOwner` functions anymore. Can only be called by the current owner. * NOTE: Renouncing ownership will leave the contract without an owner, thereby removing any functionality that is only available to the owner.\"},\"transferOwnership(address)\":{\"details\":\"Transfers ownership of the contract to a new account (`newOwner`). Can only be called by the current owner.\"}}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"@openzeppelin/contracts/ownership/Ownable.sol\":\"Ownable\"},\"evmVersion\":\"istanbul\",\"libraries\":{},\"optimizer\":{\"enabled\":true,\"runs\":10000},\"remappings\":[]},\"sources\":{\"@openzeppelin/contracts/GSN/Context.sol\":{\"keccak256\":\"0x90a3995645af7562d84b9d69363ffa5ae7217714ab61e951bf7bc450f40e4061\",\"urls\":[\"bzz-raw://216ef9d6b614db4eb46970b4e84903f2534a45572dd30a79f0041f1a5830f436\",\"dweb:/ipfs/QmNPrJ4MWKUAWzKXpUqeyKRUfosaoANZAqXgvepdrCwZAG\"]},\"@openzeppelin/contracts/ownership/Ownable.sol\":{\"keccak256\":\"0x6fb9d7889769d7cc161225f9ef7a90e468ba9788b253816f8d8b6894d3472c24\",\"urls\":[\"bzz-raw://cf4c00fc3c37cc5acf0c82ec6fd97bab67d72c2567fdc0ebf023d9c09b30a08e\",\"dweb:/ipfs/Qmb7TChG6DsEDX7LooJ4vmxot19f7VXX8S1zUGPeJTWbwZ\"]}},\"version\":1}",
"bytecode": "0x",
"deployedBytecode": "0x",
"sourceMap": "",
"deployedSourceMap": "",
"source": "pragma solidity ^0.5.0;\n\nimport \"../GSN/Context.sol\";\n/**\n * @dev Contract module which provides a basic access control mechanism, where\n * there is an account (an owner) that can be granted exclusive access to\n * specific functions.\n *\n * This module is used through inheritance. It will make available the modifier\n * `onlyOwner`, which can be applied to your functions to restrict their use to\n * the owner.\n */\ncontract Ownable is Context {\n address private _owner;\n\n event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);\n\n /**\n * @dev Initializes the contract setting the deployer as the initial owner.\n */\n constructor () internal {\n address msgSender = _msgSender();\n _owner = msgSender;\n emit OwnershipTransferred(address(0), msgSender);\n }\n\n /**\n * @dev Returns the address of the current owner.\n */\n function owner() public view returns (address) {\n return _owner;\n }\n\n /**\n * @dev Throws if called by any account other than the owner.\n */\n modifier onlyOwner() {\n require(isOwner(), \"Ownable: caller is not the owner\");\n _;\n }\n\n /**\n * @dev Returns true if the caller is the current owner.\n */\n function isOwner() public view returns (bool) {\n return _msgSender() == _owner;\n }\n\n /**\n * @dev Leaves the contract without owner. It will not be possible to call\n * `onlyOwner` functions anymore. Can only be called by the current owner.\n *\n * NOTE: Renouncing ownership will leave the contract without an owner,\n * thereby removing any functionality that is only available to the owner.\n */\n function renounceOwnership() public onlyOwner {\n emit OwnershipTransferred(_owner, address(0));\n _owner = address(0);\n }\n\n /**\n * @dev Transfers ownership of the contract to a new account (`newOwner`).\n * Can only be called by the current owner.\n */\n function transferOwnership(address newOwner) public onlyOwner {\n _transferOwnership(newOwner);\n }\n\n /**\n * @dev Transfers ownership of the contract to a new account (`newOwner`).\n */\n function _transferOwnership(address newOwner) internal {\n require(newOwner != address(0), \"Ownable: new owner is the zero address\");\n emit OwnershipTransferred(_owner, newOwner);\n _owner = newOwner;\n }\n}\n",
"sourcePath": "@openzeppelin/contracts/ownership/Ownable.sol",
"ast": {
"absolutePath": "@openzeppelin/contracts/ownership/Ownable.sol",
"exportedSymbols": {
"Ownable": [
37483
]
},
"id": 37484,
"nodeType": "SourceUnit",
"nodes": [
{
"id": 37367,
"literals": [
"solidity",
"^",
"0.5",
".0"
],
"nodeType": "PragmaDirective",
"src": "0:23:151"
},
{
"absolutePath": "@openzeppelin/contracts/GSN/Context.sol",
"file": "../GSN/Context.sol",
"id": 37368,
"nodeType": "ImportDirective",
"scope": 37484,
"sourceUnit": 37110,
"src": "25:28:151",
"symbolAliases": [],
"unitAlias": ""
},
{
"baseContracts": [
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 37369,
"name": "Context",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 37109,
"src": "435:7:151",
"typeDescriptions": {
"typeIdentifier": "t_contract$_Context_$37109",
"typeString": "contract Context"
}
},
"id": 37370,
"nodeType": "InheritanceSpecifier",
"src": "435:7:151"
}
],
"contractDependencies": [
37109
],
"contractKind": "contract",
"documentation": "@dev Contract module which provides a basic access control mechanism, where\nthere is an account (an owner) that can be granted exclusive access to\nspecific functions.\n * This module is used through inheritance. It will make available the modifier\n`onlyOwner`, which can be applied to your functions to restrict their use to\nthe owner.",
"fullyImplemented": true,
"id": 37483,
"linearizedBaseContracts": [
37483,
37109
],
"name": "Ownable",
"nodeType": "ContractDefinition",
"nodes": [
{
"constant": false,
"id": 37372,
"name": "_owner",
"nodeType": "VariableDeclaration",
"scope": 37483,
"src": "449:22:151",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 37371,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "449:7:151",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "private"
},
{
"anonymous": false,
"documentation": null,
"id": 37378,
"name": "OwnershipTransferred",
"nodeType": "EventDefinition",
"parameters": {
"id": 37377,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 37374,
"indexed": true,
"name": "previousOwner",
"nodeType": "VariableDeclaration",
"scope": 37378,
"src": "505:29:151",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 37373,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "505:7:151",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 37376,
"indexed": true,
"name": "newOwner",
"nodeType": "VariableDeclaration",
"scope": 37378,
"src": "536:24:151",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 37375,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "536:7:151",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "504:57:151"
},
"src": "478:84:151"
},
{
"body": {
"id": 37397,
"nodeType": "Block",
"src": "688:135:151",
"statements": [
{
"assignments": [
37382
],
"declarations": [
{
"constant": false,
"id": 37382,
"name": "msgSender",
"nodeType": "VariableDeclaration",
"scope": 37397,
"src": "698:17:151",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 37381,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "698:7:151",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 37385,
"initialValue": {
"argumentTypes": null,
"arguments": [],
"expression": {
"argumentTypes": [],
"id": 37383,
"name": "_msgSender",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 37097,
"src": "718:10:151",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$__$returns$_t_address_payable_$",
"typeString": "function () view returns (address payable)"
}
},
"id": 37384,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "718:12:151",
"typeDescriptions": {
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "698:32:151"
},
{
"expression": {
"argumentTypes": null,
"id": 37388,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"id": 37386,
"name": "_owner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 37372,
"src": "740:6:151",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"id": 37387,
"name": "msgSender",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 37382,
"src": "749:9:151",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"src": "740:18:151",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"id": 37389,
"nodeType": "ExpressionStatement",
"src": "740:18:151"
},
{
"eventCall": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"hexValue": "30",
"id": 37392,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "802:1:151",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
}
],
"id": 37391,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "794:7:151",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_address_$",
"typeString": "type(address)"
},
"typeName": "address"
},
"id": 37393,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "794:10:151",
"typeDescriptions": {
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
},
{
"argumentTypes": null,
"id": 37394,
"name": "msgSender",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 37382,
"src": "806:9:151",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
},
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 37390,
"name": "OwnershipTransferred",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 37378,
"src": "773:20:151",
"typeDescriptions": {
"typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$returns$__$",
"typeString": "function (address,address)"
}
},
"id": 37395,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "773:43:151",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 37396,
"nodeType": "EmitStatement",
"src": "768:48:151"
}
]
},
"documentation": "@dev Initializes the contract setting the deployer as the initial owner.",
"id": 37398,
"implemented": true,
"kind": "constructor",
"modifiers": [],
"name": "",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 37379,
"nodeType": "ParameterList",
"parameters": [],
"src": "676:2:151"
},
"returnParameters": {
"id": 37380,
"nodeType": "ParameterList",
"parameters": [],
"src": "688:0:151"
},
"scope": 37483,
"src": "664:159:151",
"stateMutability": "nonpayable",
"superFunction": null,
"visibility": "internal"
},
{
"body": {
"id": 37405,
"nodeType": "Block",
"src": "946:30:151",
"statements": [
{
"expression": {
"argumentTypes": null,
"id": 37403,
"name": "_owner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 37372,
"src": "963:6:151",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"functionReturnParameters": 37402,
"id": 37404,
"nodeType": "Return",
"src": "956:13:151"
}
]
},
"documentation": "@dev Returns the address of the current owner.",
"id": 37406,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "owner",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 37399,
"nodeType": "ParameterList",
"parameters": [],
"src": "913:2:151"
},
"returnParameters": {
"id": 37402,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 37401,
"name": "",
"nodeType": "VariableDeclaration",
"scope": 37406,
"src": "937:7:151",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 37400,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "937:7:151",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "936:9:151"
},
"scope": 37483,
"src": "899:77:151",
"stateMutability": "view",
"superFunction": 24679,
"visibility": "public"
},
{
"body": {
"id": 37415,
"nodeType": "Block",
"src": "1085:82:151",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [],
"expression": {
"argumentTypes": [],
"id": 37409,
"name": "isOwner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 37427,
"src": "1103:7:151",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$__$returns$_t_bool_$",
"typeString": "function () view returns (bool)"
}
},
"id": 37410,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "1103:9:151",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"hexValue": "4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572",
"id": 37411,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "1114:34:151",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_9924ebdf1add33d25d4ef888e16131f0a5687b0580a36c21b5c301a6c462effe",
"typeString": "literal_string \"Ownable: caller is not the owner\""
},
"value": "Ownable: caller is not the owner"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
},
{
"typeIdentifier": "t_stringliteral_9924ebdf1add33d25d4ef888e16131f0a5687b0580a36c21b5c301a6c462effe",
"typeString": "literal_string \"Ownable: caller is not the owner\""
}
],
"id": 37408,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
38110,
38111
],
"referencedDeclaration": 38111,
"src": "1095:7:151",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 37412,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "1095:54:151",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 37413,
"nodeType": "ExpressionStatement",
"src": "1095:54:151"
},
{
"id": 37414,
"nodeType": "PlaceholderStatement",
"src": "1159:1:151"
}
]
},
"documentation": "@dev Throws if called by any account other than the owner.",
"id": 37416,
"name": "onlyOwner",
"nodeType": "ModifierDefinition",
"parameters": {
"id": 37407,
"nodeType": "ParameterList",
"parameters": [],
"src": "1082:2:151"
},
"src": "1064:103:151",
"visibility": "internal"
},
{
"body": {
"id": 37426,
"nodeType": "Block",
"src": "1296:46:151",
"statements": [
{
"expression": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"id": 37424,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"arguments": [],
"expression": {
"argumentTypes": [],
"id": 37421,
"name": "_msgSender",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 37097,
"src": "1313:10:151",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$__$returns$_t_address_payable_$",
"typeString": "function () view returns (address payable)"
}
},
"id": 37422,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "1313:12:151",
"typeDescriptions": {
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
},
"nodeType": "BinaryOperation",
"operator": "==",
"rightExpression": {
"argumentTypes": null,
"id": 37423,
"name": "_owner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 37372,
"src": "1329:6:151",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"src": "1313:22:151",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"functionReturnParameters": 37420,
"id": 37425,
"nodeType": "Return",
"src": "1306:29:151"
}
]
},
"documentation": "@dev Returns true if the caller is the current owner.",
"id": 37427,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "isOwner",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 37417,
"nodeType": "ParameterList",
"parameters": [],
"src": "1266:2:151"
},
"returnParameters": {
"id": 37420,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 37419,
"name": "",
"nodeType": "VariableDeclaration",
"scope": 37427,
"src": "1290:4:151",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 37418,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "1290:4:151",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "1289:6:151"
},
"scope": 37483,
"src": "1250:92:151",
"stateMutability": "view",
"superFunction": 24684,
"visibility": "public"
},
{
"body": {
"id": 37445,
"nodeType": "Block",
"src": "1730:91:151",
"statements": [
{
"eventCall": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 37433,
"name": "_owner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 37372,
"src": "1766:6:151",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"hexValue": "30",
"id": 37435,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "1782:1:151",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
}
],
"id": 37434,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "1774:7:151",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_address_$",
"typeString": "type(address)"
},
"typeName": "address"
},
"id": 37436,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "1774:10:151",
"typeDescriptions": {
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
],
"id": 37432,
"name": "OwnershipTransferred",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 37378,
"src": "1745:20:151",
"typeDescriptions": {
"typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$returns$__$",
"typeString": "function (address,address)"
}
},
"id": 37437,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "1745:40:151",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 37438,
"nodeType": "EmitStatement",
"src": "1740:45:151"
},
{
"expression": {
"argumentTypes": null,
"id": 37443,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"id": 37439,
"name": "_owner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 37372,
"src": "1795:6:151",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"hexValue": "30",
"id": 37441,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "1812:1:151",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
}
],
"id": 37440,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "1804:7:151",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_address_$",
"typeString": "type(address)"
},
"typeName": "address"
},
"id": 37442,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "1804:10:151",
"typeDescriptions": {
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
},
"src": "1795:19:151",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"id": 37444,
"nodeType": "ExpressionStatement",
"src": "1795:19:151"
}
]
},
"documentation": "@dev Leaves the contract without owner. It will not be possible to call\n`onlyOwner` functions anymore. Can only be called by the current owner.\n * NOTE: Renouncing ownership will leave the contract without an owner,\nthereby removing any functionality that is only available to the owner.",
"id": 37446,
"implemented": true,
"kind": "function",
"modifiers": [
{
"arguments": null,
"id": 37430,
"modifierName": {
"argumentTypes": null,
"id": 37429,
"name": "onlyOwner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 37416,
"src": "1720:9:151",
"typeDescriptions": {
"typeIdentifier": "t_modifier$__$",
"typeString": "modifier ()"
}
},
"nodeType": "ModifierInvocation",
"src": "1720:9:151"
}
],
"name": "renounceOwnership",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 37428,
"nodeType": "ParameterList",
"parameters": [],
"src": "1710:2:151"
},
"returnParameters": {
"id": 37431,
"nodeType": "ParameterList",
"parameters": [],
"src": "1730:0:151"
},
"scope": 37483,
"src": "1684:137:151",
"stateMutability": "nonpayable",
"superFunction": 24687,
"visibility": "public"
},
{
"body": {
"id": 37457,
"nodeType": "Block",
"src": "2032:45:151",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 37454,
"name": "newOwner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 37448,
"src": "2061:8:151",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 37453,
"name": "_transferOwnership",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 37482,
"src": "2042:18:151",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$returns$__$",
"typeString": "function (address)"
}
},
"id": 37455,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "2042:28:151",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 37456,
"nodeType": "ExpressionStatement",
"src": "2042:28:151"
}
]
},
"documentation": "@dev Transfers ownership of the contract to a new account (`newOwner`).\nCan only be called by the current owner.",
"id": 37458,
"implemented": true,
"kind": "function",
"modifiers": [
{
"arguments": null,
"id": 37451,
"modifierName": {
"argumentTypes": null,
"id": 37450,
"name": "onlyOwner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 37416,