@etherisc/gif-contracts
Version:
This repository holds the GIF core contracts and tools to develop, test and deploy GIF instances.
1,305 lines (1,304 loc) • 56.6 kB
JSON
{
"abi": [
{
"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": "owner",
"outputs": [
{
"internalType": "address",
"name": "",
"type": "address"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "renounceOwnership",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "newOwner",
"type": "address"
}
],
"name": "transferOwnership",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
}
],
"allSourcePaths": {
"22": "/home/vscode/.brownie/packages/OpenZeppelin/openzeppelin-contracts@4.7.3/contracts/utils/Context.sol",
"4": "/home/vscode/.brownie/packages/OpenZeppelin/openzeppelin-contracts@4.7.3/contracts/access/Ownable.sol"
},
"ast": {
"absolutePath": "/home/vscode/.brownie/packages/OpenZeppelin/openzeppelin-contracts@4.7.3/contracts/access/Ownable.sol",
"exportedSymbols": {
"Context": [
24074
],
"Ownable": [
20950
]
},
"id": 20951,
"license": "MIT",
"nodeType": "SourceUnit",
"nodes": [
{
"id": 20839,
"literals": [
"solidity",
"^",
"0.8",
".0"
],
"nodeType": "PragmaDirective",
"src": "102:23:4"
},
{
"absolutePath": "/home/vscode/.brownie/packages/OpenZeppelin/openzeppelin-contracts@4.7.3/contracts/utils/Context.sol",
"file": "../utils/Context.sol",
"id": 20840,
"nameLocation": "-1:-1:-1",
"nodeType": "ImportDirective",
"scope": 20951,
"sourceUnit": 24075,
"src": "127:30:4",
"symbolAliases": [],
"unitAlias": ""
},
{
"abstract": true,
"baseContracts": [
{
"baseName": {
"id": 20842,
"name": "Context",
"nodeType": "IdentifierPath",
"referencedDeclaration": 24074,
"src": "683:7:4"
},
"id": 20843,
"nodeType": "InheritanceSpecifier",
"src": "683:7:4"
}
],
"contractDependencies": [
24074
],
"contractKind": "contract",
"documentation": {
"id": 20841,
"nodeType": "StructuredDocumentation",
"src": "159:494:4",
"text": " @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 By default, the owner account will be the one that deploys the contract. This\n can later be changed with {transferOwnership}.\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."
},
"fullyImplemented": true,
"id": 20950,
"linearizedBaseContracts": [
20950,
24074
],
"name": "Ownable",
"nameLocation": "672:7:4",
"nodeType": "ContractDefinition",
"nodes": [
{
"constant": false,
"id": 20845,
"mutability": "mutable",
"name": "_owner",
"nameLocation": "713:6:4",
"nodeType": "VariableDeclaration",
"scope": 20950,
"src": "697:22:4",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 20844,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "697:7:4",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"visibility": "private"
},
{
"anonymous": false,
"id": 20851,
"name": "OwnershipTransferred",
"nameLocation": "732:20:4",
"nodeType": "EventDefinition",
"parameters": {
"id": 20850,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 20847,
"indexed": true,
"mutability": "mutable",
"name": "previousOwner",
"nameLocation": "769:13:4",
"nodeType": "VariableDeclaration",
"scope": 20851,
"src": "753:29:4",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 20846,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "753:7:4",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"visibility": "internal"
},
{
"constant": false,
"id": 20849,
"indexed": true,
"mutability": "mutable",
"name": "newOwner",
"nameLocation": "800:8:4",
"nodeType": "VariableDeclaration",
"scope": 20851,
"src": "784:24:4",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 20848,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "784:7:4",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"visibility": "internal"
}
],
"src": "752:57:4"
},
"src": "726:84:4"
},
{
"body": {
"id": 20860,
"nodeType": "Block",
"src": "926:49:4",
"statements": [
{
"expression": {
"arguments": [
{
"arguments": [],
"expression": {
"argumentTypes": [],
"id": 20856,
"name": "_msgSender",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 24064,
"src": "955:10:4",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$__$returns$_t_address_$",
"typeString": "function () view returns (address)"
}
},
"id": 20857,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "955:12:4",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 20855,
"name": "_transferOwnership",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 20949,
"src": "936:18:4",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$returns$__$",
"typeString": "function (address)"
}
},
"id": 20858,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "936:32:4",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 20859,
"nodeType": "ExpressionStatement",
"src": "936:32:4"
}
]
},
"documentation": {
"id": 20852,
"nodeType": "StructuredDocumentation",
"src": "816:91:4",
"text": " @dev Initializes the contract setting the deployer as the initial owner."
},
"id": 20861,
"implemented": true,
"kind": "constructor",
"modifiers": [],
"name": "",
"nameLocation": "-1:-1:-1",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 20853,
"nodeType": "ParameterList",
"parameters": [],
"src": "923:2:4"
},
"returnParameters": {
"id": 20854,
"nodeType": "ParameterList",
"parameters": [],
"src": "926:0:4"
},
"scope": 20950,
"src": "912:63:4",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 20868,
"nodeType": "Block",
"src": "1084:41:4",
"statements": [
{
"expression": {
"arguments": [],
"expression": {
"argumentTypes": [],
"id": 20864,
"name": "_checkOwner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 20892,
"src": "1094:11:4",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$__$returns$__$",
"typeString": "function () view"
}
},
"id": 20865,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "1094:13:4",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 20866,
"nodeType": "ExpressionStatement",
"src": "1094:13:4"
},
{
"id": 20867,
"nodeType": "PlaceholderStatement",
"src": "1117:1:4"
}
]
},
"documentation": {
"id": 20862,
"nodeType": "StructuredDocumentation",
"src": "981:77:4",
"text": " @dev Throws if called by any account other than the owner."
},
"id": 20869,
"name": "onlyOwner",
"nameLocation": "1072:9:4",
"nodeType": "ModifierDefinition",
"parameters": {
"id": 20863,
"nodeType": "ParameterList",
"parameters": [],
"src": "1081:2:4"
},
"src": "1063:62:4",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 20877,
"nodeType": "Block",
"src": "1256:30:4",
"statements": [
{
"expression": {
"id": 20875,
"name": "_owner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 20845,
"src": "1273:6:4",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"functionReturnParameters": 20874,
"id": 20876,
"nodeType": "Return",
"src": "1266:13:4"
}
]
},
"documentation": {
"id": 20870,
"nodeType": "StructuredDocumentation",
"src": "1131:65:4",
"text": " @dev Returns the address of the current owner."
},
"functionSelector": "8da5cb5b",
"id": 20878,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "owner",
"nameLocation": "1210:5:4",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 20871,
"nodeType": "ParameterList",
"parameters": [],
"src": "1215:2:4"
},
"returnParameters": {
"id": 20874,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 20873,
"mutability": "mutable",
"name": "",
"nameLocation": "-1:-1:-1",
"nodeType": "VariableDeclaration",
"scope": 20878,
"src": "1247:7:4",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 20872,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "1247:7:4",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"visibility": "internal"
}
],
"src": "1246:9:4"
},
"scope": 20950,
"src": "1201:85:4",
"stateMutability": "view",
"virtual": true,
"visibility": "public"
},
{
"body": {
"id": 20891,
"nodeType": "Block",
"src": "1404:85:4",
"statements": [
{
"expression": {
"arguments": [
{
"commonType": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"id": 20887,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"arguments": [],
"expression": {
"argumentTypes": [],
"id": 20883,
"name": "owner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 20878,
"src": "1422:5:4",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$__$returns$_t_address_$",
"typeString": "function () view returns (address)"
}
},
"id": 20884,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "1422:7:4",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "BinaryOperation",
"operator": "==",
"rightExpression": {
"arguments": [],
"expression": {
"argumentTypes": [],
"id": 20885,
"name": "_msgSender",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 24064,
"src": "1433:10:4",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$__$returns$_t_address_$",
"typeString": "function () view returns (address)"
}
},
"id": 20886,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "1433:12:4",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"src": "1422:23:4",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"hexValue": "4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572",
"id": 20888,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "1447:34:4",
"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": 20882,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "1414:7:4",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 20889,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "1414:68:4",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 20890,
"nodeType": "ExpressionStatement",
"src": "1414:68:4"
}
]
},
"documentation": {
"id": 20879,
"nodeType": "StructuredDocumentation",
"src": "1292:62:4",
"text": " @dev Throws if the sender is not the owner."
},
"id": 20892,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "_checkOwner",
"nameLocation": "1368:11:4",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 20880,
"nodeType": "ParameterList",
"parameters": [],
"src": "1379:2:4"
},
"returnParameters": {
"id": 20881,
"nodeType": "ParameterList",
"parameters": [],
"src": "1404:0:4"
},
"scope": 20950,
"src": "1359:130:4",
"stateMutability": "view",
"virtual": true,
"visibility": "internal"
},
{
"body": {
"id": 20905,
"nodeType": "Block",
"src": "1885:47:4",
"statements": [
{
"expression": {
"arguments": [
{
"arguments": [
{
"hexValue": "30",
"id": 20901,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "1922:1:4",
"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": 20900,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "1914:7:4",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_address_$",
"typeString": "type(address)"
},
"typeName": {
"id": 20899,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "1914:7:4",
"typeDescriptions": {}
}
},
"id": 20902,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "1914:10:4",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 20898,
"name": "_transferOwnership",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 20949,
"src": "1895:18:4",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$returns$__$",
"typeString": "function (address)"
}
},
"id": 20903,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "1895:30:4",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 20904,
"nodeType": "ExpressionStatement",
"src": "1895:30:4"
}
]
},
"documentation": {
"id": 20893,
"nodeType": "StructuredDocumentation",
"src": "1495:331:4",
"text": " @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,\n thereby removing any functionality that is only available to the owner."
},
"functionSelector": "715018a6",
"id": 20906,
"implemented": true,
"kind": "function",
"modifiers": [
{
"id": 20896,
"modifierName": {
"id": 20895,
"name": "onlyOwner",
"nodeType": "IdentifierPath",
"referencedDeclaration": 20869,
"src": "1875:9:4"
},
"nodeType": "ModifierInvocation",
"src": "1875:9:4"
}
],
"name": "renounceOwnership",
"nameLocation": "1840:17:4",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 20894,
"nodeType": "ParameterList",
"parameters": [],
"src": "1857:2:4"
},
"returnParameters": {
"id": 20897,
"nodeType": "ParameterList",
"parameters": [],
"src": "1885:0:4"
},
"scope": 20950,
"src": "1831:101:4",
"stateMutability": "nonpayable",
"virtual": true,
"visibility": "public"
},
{
"body": {
"id": 20928,
"nodeType": "Block",
"src": "2151:128:4",
"statements": [
{
"expression": {
"arguments": [
{
"commonType": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"id": 20920,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"id": 20915,
"name": "newOwner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 20909,
"src": "2169:8:4",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "BinaryOperation",
"operator": "!=",
"rightExpression": {
"arguments": [
{
"hexValue": "30",
"id": 20918,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "2189:1:4",
"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": 20917,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "2181:7:4",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_address_$",
"typeString": "type(address)"
},
"typeName": {
"id": 20916,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "2181:7:4",
"typeDescriptions": {}
}
},
"id": 20919,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "2181:10:4",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"src": "2169:22:4",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"hexValue": "4f776e61626c653a206e6577206f776e657220697320746865207a65726f2061646472657373",
"id": 20921,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "2193:40:4",
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_245f15ff17f551913a7a18385165551503906a406f905ac1c2437281a7cd0cfe",
"typeString": "literal_string \"Ownable: new owner is the zero address\""
},
"value": "Ownable: new owner is the zero address"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
},
{
"typeIdentifier": "t_stringliteral_245f15ff17f551913a7a18385165551503906a406f905ac1c2437281a7cd0cfe",
"typeString": "literal_string \"Ownable: new owner is the zero address\""
}
],
"id": 20914,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "2161:7:4",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 20922,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "2161:73:4",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 20923,
"nodeType": "ExpressionStatement",
"src": "2161:73:4"
},
{
"expression": {
"arguments": [
{
"id": 20925,
"name": "newOwner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 20909,
"src": "2263:8:4",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 20924,
"name": "_transferOwnership",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 20949,
"src": "2244:18:4",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$returns$__$",
"typeString": "function (address)"
}
},
"id": 20926,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "2244:28:4",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 20927,
"nodeType": "ExpressionStatement",
"src": "2244:28:4"
}
]
},
"documentation": {
"id": 20907,
"nodeType": "StructuredDocumentation",
"src": "1938:138:4",
"text": " @dev Transfers ownership of the contract to a new account (`newOwner`).\n Can only be called by the current owner."
},
"functionSelector": "f2fde38b",
"id": 20929,
"implemented": true,
"kind": "function",
"modifiers": [
{
"id": 20912,
"modifierName": {
"id": 20911,
"name": "onlyOwner",
"nodeType": "IdentifierPath",
"referencedDeclaration": 20869,
"src": "2141:9:4"
},
"nodeType": "ModifierInvocation",
"src": "2141:9:4"
}
],
"name": "transferOwnership",
"nameLocation": "2090:17:4",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 20910,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 20909,
"mutability": "mutable",
"name": "newOwner",
"nameLocation": "2116:8:4",
"nodeType": "VariableDeclaration",
"scope": 20929,
"src": "2108:16:4",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 20908,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "2108:7:4",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"visibility": "internal"
}
],
"src": "2107:18:4"
},
"returnParameters": {
"id": 20913,
"nodeType": "ParameterList",
"parameters": [],
"src": "2151:0:4"
},
"scope": 20950,
"src": "2081:198:4",
"stateMutability": "nonpayable",
"virtual": true,
"visibility": "public"
},
{
"body": {
"id": 20948,
"nodeType": "Block",
"src": "2496:124:4",
"statements": [
{
"assignments": [
20936
],
"declarations": [
{
"constant": false,
"id": 20936,
"mutability": "mutable",
"name": "oldOwner",
"nameLocation": "2514:8:4",
"nodeType": "VariableDeclaration",
"scope": 20948,
"src": "2506:16:4",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 20935,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "2506:7:4",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"visibility": "internal"
}
],
"id": 20938,
"initialValue": {
"id": 20937,
"name": "_owner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 20845,
"src": "2525:6:4",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "2506:25:4"
},
{
"expression": {
"id": 20941,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"id": 20939,
"name": "_owner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 20845,
"src": "2541:6:4",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"id": 20940,
"name": "newOwner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 20932,
"src": "2550:8:4",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"src": "2541:17:4",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"id": 20942,
"nodeType": "ExpressionStatement",
"src": "2541:17:4"
},
{
"eventCall": {
"arguments": [
{
"id": 20944,
"name": "oldOwner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 20936,
"src": "2594:8:4",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"id": 20945,
"name": "newOwner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 20932,
"src": "2604:8:4",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 20943,
"name": "OwnershipTransferred",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 20851,
"src": "2573:20:4",
"typeDescriptions": {
"typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$returns$__$",
"typeString": "function (address,address)"
}
},
"id": 20946,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "2573:40:4",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 20947,
"nodeType": "EmitStatement",
"src": "2568:45:4"
}
]
},
"documentation": {
"id": 20930,
"nodeType": "StructuredDocumentation",
"src": "2285:143:4",
"text": " @dev Transfers ownership of the contract to a new account (`newOwner`).\n Internal function without access restriction."
},
"id": 20949,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "_transferOwnership",
"nameLocation": "2442:18:4",