UNPKG

@ethsub/sol

Version:
1,281 lines (1,280 loc) 93.8 kB
{ "contractName": "Pausable", "abi": [ { "anonymous": false, "inputs": [ { "indexed": false, "internalType": "address", "name": "account", "type": "address" } ], "name": "Paused", "type": "event" }, { "anonymous": false, "inputs": [ { "indexed": false, "internalType": "address", "name": "account", "type": "address" } ], "name": "Unpaused", "type": "event" }, { "inputs": [], "name": "paused", "outputs": [ { "internalType": "bool", "name": "", "type": "bool" } ], "stateMutability": "view", "type": "function" } ], "metadata": "{\"compiler\":{\"version\":\"0.6.12+commit.27d51765\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"}],\"devdoc\":{\"details\":\"Contract module which allows children to implement an emergency stop mechanism that can be triggered by an authorized account. This is a stripped down version of Open zeppelin's Pausable contract. https://github.com/OpenZeppelin/openzeppelin-contracts/blob/master/contracts/utils/EnumerableSet.sol\",\"events\":{\"Paused(address)\":{\"details\":\"Emitted when the pause is triggered by `account`.\"},\"Unpaused(address)\":{\"details\":\"Emitted when the pause is lifted by `account`.\"}},\"kind\":\"dev\",\"methods\":{\"constructor\":{\"details\":\"Initializes the contract in unpaused state.\"},\"paused()\":{\"details\":\"Returns true if the contract is paused, and false otherwise.\"}},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"project:/contracts/utils/Pausable.sol\":\"Pausable\"},\"evmVersion\":\"istanbul\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":true,\"runs\":200},\"remappings\":[]},\"sources\":{\"project:/contracts/utils/Pausable.sol\":{\"keccak256\":\"0xdb3e06f23d6b39b47c554e28cf83e7da130ffda988b2261544c616b2ce291dac\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://3be9b9a9ca3c25d63231fc8e451616e4e9a0278a62e4ba01fb5dcda3f9672b57\",\"dweb:/ipfs/QmRDstUdMb4EBHQL3zue22Pz9Ey2K4qfa2Yp1sQRwgT7YC\"]}},\"version\":1}", "bytecode": "0x", "deployedBytecode": "0x", "immutableReferences": {}, "sourceMap": "", "deployedSourceMap": "", "source": "// SPDX-License-Identifier: MIT\n\npragma solidity 0.6.12;\n\n\n/**\n * @dev Contract module which allows children to implement an emergency stop\n * mechanism that can be triggered by an authorized account.\n *\n * This is a stripped down version of Open zeppelin's Pausable contract.\n * https://github.com/OpenZeppelin/openzeppelin-contracts/blob/master/contracts/utils/EnumerableSet.sol\n *\n */\ncontract Pausable {\n /**\n * @dev Emitted when the pause is triggered by `account`.\n */\n event Paused(address account);\n\n /**\n * @dev Emitted when the pause is lifted by `account`.\n */\n event Unpaused(address account);\n\n bool private _paused;\n\n /**\n * @dev Initializes the contract in unpaused state.\n */\n constructor () internal {\n _paused = false;\n }\n\n /**\n * @dev Returns true if the contract is paused, and false otherwise.\n */\n function paused() public view returns (bool) {\n return _paused;\n }\n\n /**\n * @dev Modifier to make a function callable only when the contract is not paused.\n *\n * Requirements:\n *\n * - The contract must not be paused.\n */\n modifier whenNotPaused() {\n _whenNotPaused();\n _;\n }\n\n function _whenNotPaused() private view {\n require(!_paused, \"Pausable: paused\");\n }\n\n /**\n * @dev Modifier to make a function callable only when the contract is not paused.\n *\n * Requirements:\n *\n * - The contract must not be paused.\n */\n modifier whenPaused() {\n _whenPaused();\n _;\n }\n\n function _whenPaused() private view {\n require(_paused, \"Pausable: not paused\");\n }\n\n /**\n * @dev Triggers stopped state.\n *\n * Requirements:\n *\n * - The contract must not be paused.\n */\n function _pause() internal virtual whenNotPaused {\n _paused = true;\n emit Paused(msg.sender);\n }\n\n /**\n * @dev Returns to normal state.\n *\n * Requirements:\n *\n * - The contract must be paused.\n */\n function _unpause() internal virtual whenPaused {\n _paused = false;\n emit Unpaused(msg.sender);\n }\n}", "sourcePath": "/home/sigo/w/deer/ethsub/packages/sol/contracts/utils/Pausable.sol", "ast": { "absolutePath": "project:/contracts/utils/Pausable.sol", "exportedSymbols": { "Pausable": [ 10250 ] }, "id": 10251, "license": "MIT", "nodeType": "SourceUnit", "nodes": [ { "id": 10151, "literals": [ "solidity", "0.6", ".12" ], "nodeType": "PragmaDirective", "src": "33:23:54" }, { "abstract": false, "baseContracts": [], "contractDependencies": [], "contractKind": "contract", "documentation": { "id": 10152, "nodeType": "StructuredDocumentation", "src": "59:328:54", "text": " @dev Contract module which allows children to implement an emergency stop\n mechanism that can be triggered by an authorized account.\n This is a stripped down version of Open zeppelin's Pausable contract.\n https://github.com/OpenZeppelin/openzeppelin-contracts/blob/master/contracts/utils/EnumerableSet.sol" }, "fullyImplemented": true, "id": 10250, "linearizedBaseContracts": [ 10250 ], "name": "Pausable", "nodeType": "ContractDefinition", "nodes": [ { "anonymous": false, "documentation": { "id": 10153, "nodeType": "StructuredDocumentation", "src": "412:73:54", "text": " @dev Emitted when the pause is triggered by `account`." }, "id": 10157, "name": "Paused", "nodeType": "EventDefinition", "parameters": { "id": 10156, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 10155, "indexed": false, "mutability": "mutable", "name": "account", "nodeType": "VariableDeclaration", "overrides": null, "scope": 10157, "src": "503:15:54", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 10154, "name": "address", "nodeType": "ElementaryTypeName", "src": "503:7:54", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "value": null, "visibility": "internal" } ], "src": "502:17:54" }, "src": "490:30:54" }, { "anonymous": false, "documentation": { "id": 10158, "nodeType": "StructuredDocumentation", "src": "526:70:54", "text": " @dev Emitted when the pause is lifted by `account`." }, "id": 10162, "name": "Unpaused", "nodeType": "EventDefinition", "parameters": { "id": 10161, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 10160, "indexed": false, "mutability": "mutable", "name": "account", "nodeType": "VariableDeclaration", "overrides": null, "scope": 10162, "src": "616:15:54", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 10159, "name": "address", "nodeType": "ElementaryTypeName", "src": "616:7:54", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "value": null, "visibility": "internal" } ], "src": "615:17:54" }, "src": "601:32:54" }, { "constant": false, "id": 10164, "mutability": "mutable", "name": "_paused", "nodeType": "VariableDeclaration", "overrides": null, "scope": 10250, "src": "639:20:54", "stateVariable": true, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" }, "typeName": { "id": 10163, "name": "bool", "nodeType": "ElementaryTypeName", "src": "639:4:54", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "value": null, "visibility": "private" }, { "body": { "id": 10172, "nodeType": "Block", "src": "762:32:54", "statements": [ { "expression": { "argumentTypes": null, "id": 10170, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, "id": 10168, "name": "_paused", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 10164, "src": "772:7:54", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "nodeType": "Assignment", "operator": "=", "rightHandSide": { "argumentTypes": null, "hexValue": "66616c7365", "id": 10169, "isConstant": false, "isLValue": false, "isPure": true, "kind": "bool", "lValueRequested": false, "nodeType": "Literal", "src": "782:5:54", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" }, "value": "false" }, "src": "772:15:54", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "id": 10171, "nodeType": "ExpressionStatement", "src": "772:15:54" } ] }, "documentation": { "id": 10165, "nodeType": "StructuredDocumentation", "src": "666:67:54", "text": " @dev Initializes the contract in unpaused state." }, "id": 10173, "implemented": true, "kind": "constructor", "modifiers": [], "name": "", "nodeType": "FunctionDefinition", "overrides": null, "parameters": { "id": 10166, "nodeType": "ParameterList", "parameters": [], "src": "750:2:54" }, "returnParameters": { "id": 10167, "nodeType": "ParameterList", "parameters": [], "src": "762:0:54" }, "scope": 10250, "src": "738:56:54", "stateMutability": "nonpayable", "virtual": false, "visibility": "internal" }, { "body": { "id": 10181, "nodeType": "Block", "src": "934:31:54", "statements": [ { "expression": { "argumentTypes": null, "id": 10179, "name": "_paused", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 10164, "src": "951:7:54", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "functionReturnParameters": 10178, "id": 10180, "nodeType": "Return", "src": "944:14:54" } ] }, "documentation": { "id": 10174, "nodeType": "StructuredDocumentation", "src": "800:84:54", "text": " @dev Returns true if the contract is paused, and false otherwise." }, "functionSelector": "5c975abb", "id": 10182, "implemented": true, "kind": "function", "modifiers": [], "name": "paused", "nodeType": "FunctionDefinition", "overrides": null, "parameters": { "id": 10175, "nodeType": "ParameterList", "parameters": [], "src": "904:2:54" }, "returnParameters": { "id": 10178, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 10177, "mutability": "mutable", "name": "", "nodeType": "VariableDeclaration", "overrides": null, "scope": 10182, "src": "928:4:54", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" }, "typeName": { "id": 10176, "name": "bool", "nodeType": "ElementaryTypeName", "src": "928:4:54", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "value": null, "visibility": "internal" } ], "src": "927:6:54" }, "scope": 10250, "src": "889:76:54", "stateMutability": "view", "virtual": false, "visibility": "public" }, { "body": { "id": 10189, "nodeType": "Block", "src": "1176:44:54", "statements": [ { "expression": { "argumentTypes": null, "arguments": [], "expression": { "argumentTypes": [], "id": 10185, "name": "_whenNotPaused", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 10200, "src": "1186:14:54", "typeDescriptions": { "typeIdentifier": "t_function_internal_view$__$returns$__$", "typeString": "function () view" } }, "id": 10186, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1186:16:54", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, "id": 10187, "nodeType": "ExpressionStatement", "src": "1186:16:54" }, { "id": 10188, "nodeType": "PlaceholderStatement", "src": "1212:1:54" } ] }, "documentation": { "id": 10183, "nodeType": "StructuredDocumentation", "src": "971:175:54", "text": " @dev Modifier to make a function callable only when the contract is not paused.\n Requirements:\n - The contract must not be paused." }, "id": 10190, "name": "whenNotPaused", "nodeType": "ModifierDefinition", "overrides": null, "parameters": { "id": 10184, "nodeType": "ParameterList", "parameters": [], "src": "1173:2:54" }, "src": "1151:69:54", "virtual": false, "visibility": "internal" }, { "body": { "id": 10199, "nodeType": "Block", "src": "1265:54:54", "statements": [ { "expression": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "id": 10195, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "nodeType": "UnaryOperation", "operator": "!", "prefix": true, "src": "1283:8:54", "subExpression": { "argumentTypes": null, "id": 10194, "name": "_paused", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 10164, "src": "1284:7:54", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, { "argumentTypes": null, "hexValue": "5061757361626c653a20706175736564", "id": 10196, "isConstant": false, "isLValue": false, "isPure": true, "kind": "string", "lValueRequested": false, "nodeType": "Literal", "src": "1293:18:54", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_stringliteral_68571e1369f7a6dcdcd736cb0343b35a58ed0f64d245c2ed839c98d412744f8a", "typeString": "literal_string \"Pausable: paused\"" }, "value": "Pausable: paused" } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_bool", "typeString": "bool" }, { "typeIdentifier": "t_stringliteral_68571e1369f7a6dcdcd736cb0343b35a58ed0f64d245c2ed839c98d412744f8a", "typeString": "literal_string \"Pausable: paused\"" } ], "id": 10193, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ -18, -18 ], "referencedDeclaration": -18, "src": "1275:7:54", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, "id": 10197, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1275:37:54", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, "id": 10198, "nodeType": "ExpressionStatement", "src": "1275:37:54" } ] }, "documentation": null, "id": 10200, "implemented": true, "kind": "function", "modifiers": [], "name": "_whenNotPaused", "nodeType": "FunctionDefinition", "overrides": null, "parameters": { "id": 10191, "nodeType": "ParameterList", "parameters": [], "src": "1249:2:54" }, "returnParameters": { "id": 10192, "nodeType": "ParameterList", "parameters": [], "src": "1265:0:54" }, "scope": 10250, "src": "1226:93:54", "stateMutability": "view", "virtual": false, "visibility": "private" }, { "body": { "id": 10207, "nodeType": "Block", "src": "1527:41:54", "statements": [ { "expression": { "argumentTypes": null, "arguments": [], "expression": { "argumentTypes": [], "id": 10203, "name": "_whenPaused", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 10217, "src": "1537:11:54", "typeDescriptions": { "typeIdentifier": "t_function_internal_view$__$returns$__$", "typeString": "function () view" } }, "id": 10204, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1537:13:54", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, "id": 10205, "nodeType": "ExpressionStatement", "src": "1537:13:54" }, { "id": 10206, "nodeType": "PlaceholderStatement", "src": "1560:1:54" } ] }, "documentation": { "id": 10201, "nodeType": "StructuredDocumentation", "src": "1325:175:54", "text": " @dev Modifier to make a function callable only when the contract is not paused.\n Requirements:\n - The contract must not be paused." }, "id": 10208, "name": "whenPaused", "nodeType": "ModifierDefinition", "overrides": null, "parameters": { "id": 10202, "nodeType": "ParameterList", "parameters": [], "src": "1524:2:54" }, "src": "1505:63:54", "virtual": false, "visibility": "internal" }, { "body": { "id": 10216, "nodeType": "Block", "src": "1610:57:54", "statements": [ { "expression": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "id": 10212, "name": "_paused", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 10164, "src": "1628:7:54", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, { "argumentTypes": null, "hexValue": "5061757361626c653a206e6f7420706175736564", "id": 10213, "isConstant": false, "isLValue": false, "isPure": true, "kind": "string", "lValueRequested": false, "nodeType": "Literal", "src": "1637:22:54", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_stringliteral_0d1d997348c4b502650619e51f7d09f80514d98b6993be5051d07f703984619a", "typeString": "literal_string \"Pausable: not paused\"" }, "value": "Pausable: not paused" } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_bool", "typeString": "bool" }, { "typeIdentifier": "t_stringliteral_0d1d997348c4b502650619e51f7d09f80514d98b6993be5051d07f703984619a", "typeString": "literal_string \"Pausable: not paused\"" } ], "id": 10211, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ -18, -18 ], "referencedDeclaration": -18, "src": "1620:7:54", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, "id": 10214, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1620:40:54", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, "id": 10215, "nodeType": "ExpressionStatement", "src": "1620:40:54" } ] }, "documentation": null, "id": 10217, "implemented": true, "kind": "function", "modifiers": [], "name": "_whenPaused", "nodeType": "FunctionDefinition", "overrides": null, "parameters": { "id": 10209, "nodeType": "ParameterList", "parameters": [], "src": "1594:2:54" }, "returnParameters": { "id": 10210, "nodeType": "ParameterList", "parameters": [], "src": "1610:0:54" }, "scope": 10250, "src": "1574:93:54", "stateMutability": "view", "virtual": false, "visibility": "private" }, { "body": { "id": 10232, "nodeType": "Block", "src": "1851:64:54", "statements": [ { "expression": { "argumentTypes": null, "id": 10225, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, "id": 10223, "name": "_paused", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 10164, "src": "1861:7:54", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "nodeType": "Assignment", "operator": "=", "rightHandSide": { "argumentTypes": null, "hexValue": "74727565", "id": 10224, "isConstant": false, "isLValue": false, "isPure": true, "kind": "bool", "lValueRequested": false, "nodeType": "Literal", "src": "1871:4:54", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" }, "value": "true" }, "src": "1861:14:54", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "id": 10226, "nodeType": "ExpressionStatement", "src": "1861:14:54" }, { "eventCall": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 10228, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": -15, "src": "1897:3:54", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, "id": 10229, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, "src": "1897:10:54", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_address_payable", "typeString": "address payable" } ], "id": 10227, "name": "Paused", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 10157, "src": "1890:6:54", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$", "typeString": "function (address)" } }, "id": 10230, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1890:18:54", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, "id": 10231, "nodeType": "EmitStatement", "src": "1885:23:54" } ] }, "documentation": { "id": 10218, "nodeType": "StructuredDocumentation", "src": "1673:124:54", "text": " @dev Triggers stopped state.\n Requirements:\n - The contract must not be paused." }, "id": 10233, "implemented": true, "kind": "function", "modifiers": [ { "arguments": null, "id": 10221, "modifierName": { "argumentTypes": null, "id": 10220, "name": "whenNotPaused", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 10190, "src": "1837:13:54", "typeDescriptions": { "typeIdentifier": "t_modifier$__$", "typeString": "modifier ()" } }, "nodeType": "ModifierInvocation", "src": "1837:13:54" } ], "name": "_pause", "nodeType": "FunctionDefinition", "overrides": null, "parameters": { "id": 10219, "nodeType": "ParameterList", "parameters": [], "src": "1817:2:54" }, "returnParameters": { "id": 10222, "nodeType": "ParameterList", "parameters": [], "src": "1851:0:54" }, "scope": 10250, "src": "1802:113:54", "stateMutability": "nonpayable", "virtual": true, "visibility": "internal" }, { "body": { "id": 10248, "nodeType": "Block", "src": "2095:67:54", "statements": [ { "expression": { "argumentTypes": null, "id": 10241, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, "id": 10239, "name": "_paused", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 10164, "src": "2105:7:54", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "nodeType": "Assignment", "operator": "=", "rightHandSide": { "argumentTypes": null, "hexValue": "66616c7365", "id": 10240, "isConstant": false, "isLValue": false, "isPure": true, "kind": "bool", "lValueRequested": false, "nodeType": "Literal", "src": "2115:5:54", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" }, "value": "false" }, "src": "2105:15:54", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "id": 10242, "nodeType": "ExpressionStatement", "src": "2105:15:54" }, { "eventCall": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 10244, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": -15, "src": "2144:3:54", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, "id": 10245, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, "src": "2144:10:54", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_address_payable", "typeString": "address payable" } ], "id": 10243, "name": "Unpaused", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 10162, "src": "2135:8:54", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$", "typeString": "function (address)" } }, "id": 10246, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "2135:20:54", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, "id": 10247, "nodeType": "EmitStatement", "src": "2130:25:54" } ] }, "documentation": { "id": 10234, "nodeType": "StructuredDocumentation", "src": "1921:121:54", "text": " @dev Returns to normal state.\n Requirements:\n - The contract must be paused." }, "id": 10249, "implemented": true, "kind": "function", "modifiers": [ { "arguments": null, "id": 10237, "modifierName": { "argumentTypes": null, "id": 10236, "name": "whenPaused", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 10208, "src": "2084:10:54", "typeDescriptions": { "typeIdentifier": "t_modifier$__$", "typeString": "modifier ()" } }, "nodeType": "ModifierInvocation", "src": "2084:10:54" } ], "name": "_unpause", "nodeType": "FunctionDefinition", "overrides": null, "parameters": { "id": 10235, "nodeType": "ParameterList", "parameters": [], "src": "2064:2:54" }, "returnParameters": { "id": 10238, "nodeType": "ParameterList", "parameters": [], "src": "2095:0:54" }, "scope": 10250, "src": "2047:115:54", "stateMutability": "nonpayable", "virtual": true, "visibility": "internal" } ], "scope": 10251, "src": "388:1776:54" } ], "src": "33:2131:54" }, "legacyAST": { "attributes": { "absolutePath": "project:/contracts/utils/Pausable.sol", "exportedSymbols": { "Pausable": [ 10250 ] }, "license": "MIT" }, "children": [ { "attributes": { "literals": [ "solidity", "0.6", ".12" ] }, "id": 10151, "name": "PragmaDirective", "src": "33:23:54" }, { "attributes": { "abstract": false, "baseContracts": [ null ], "contractDependencies": [ null ], "contractKind": "contract", "fullyImplemented": true, "linearizedBaseContracts": [ 10250 ], "name": "Pausable", "scope": 10251 }, "children": [ { "attributes": { "text": " @dev Contract module which allows children to implement an emergency stop\n mechanism that can be triggered by an authorized account.\n This is a stripped down version of Open zeppelin's Pausable contract.\n https://github.com/OpenZeppelin/openzeppelin-contracts/blob/master/contracts/utils/EnumerableSet.sol" }, "id": 10152, "name": "StructuredDocumentation", "src": "59:328:54" }, { "attributes": { "anonymous": false, "name": "Paused" }, "children": [ { "attributes": { "text": " @dev Emitted when the pause is triggered by `account`." }, "id": 10153, "name": "StructuredDocumentation", "src": "412:73:54" }, { "children": [ { "attributes": { "constant": false, "indexed": false, "mutability": "mutable", "name": "account", "overrides": null, "scope": 10157, "stateVariable": false, "storageLocation": "default", "type": "address", "value": null, "visibility": "internal" }, "children": [ { "attributes": { "name": "address", "stateMutability": "nonpayable", "type": "address" }, "id": 10154, "name": "ElementaryTypeName", "src": "503:7:54" } ], "id": 10155, "name": "VariableDeclaration", "src": "503:15:54" } ], "id": 10156, "name": "ParameterList", "src": "502:17:54" } ], "id": 10157, "name": "EventDefinition", "src": "490:30:54" }, { "attributes": { "anonymous": false, "name": "Unpaused" }, "children": [ { "attributes": { "text": " @dev Emitted when the pause is lifted by `account`." }, "id": 10158, "name": "StructuredDocumentation", "src": "526:70:54" }, { "children": [ { "attributes": { "constant": false, "indexed": false, "mutability": "mutable", "name": "account", "overrides": null, "scope": 10162, "stateVariable": false, "storageLocation": "default", "type": "address",