becrypto/build/contracts/MallBase.json
2023-09-06 13:54:51 +08:00

1602 lines
63 KiB
JSON

{
"contractName": "MallBase",
"abi": [
{
"anonymous": false,
"inputs": [
{
"indexed": false,
"internalType": "address",
"name": "erc20",
"type": "address"
}
],
"name": "AddERC20Suppout",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "address",
"name": "previousOwner",
"type": "address"
},
{
"indexed": true,
"internalType": "address",
"name": "newOwner",
"type": "address"
}
],
"name": "OwnershipTransferred",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": false,
"internalType": "address",
"name": "erc20",
"type": "address"
}
],
"name": "RemoveERC20Suppout",
"type": "event"
},
{
"inputs": [
{
"internalType": "address",
"name": "",
"type": "address"
}
],
"name": "erc20Supported",
"outputs": [
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "executor",
"outputs": [
{
"internalType": "address",
"name": "",
"type": "address"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "feeToAddress",
"outputs": [
{
"internalType": "address",
"name": "",
"type": "address"
}
],
"stateMutability": "view",
"type": "function"
},
{
"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"
},
{
"inputs": [
{
"internalType": "address",
"name": "erc20",
"type": "address"
}
],
"name": "addERC20Support",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "erc20",
"type": "address"
}
],
"name": "removeERC20Support",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "account",
"type": "address"
}
],
"name": "updateExecutor",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "_feeToAddress",
"type": "address"
}
],
"name": "setFeeToAddress",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
}
],
"metadata": "{\"compiler\":{\"version\":\"0.8.10+commit.fc410830\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"erc20\",\"type\":\"address\"}],\"name\":\"AddERC20Suppout\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"previousOwner\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"OwnershipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"erc20\",\"type\":\"address\"}],\"name\":\"RemoveERC20Suppout\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"erc20\",\"type\":\"address\"}],\"name\":\"addERC20Support\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"erc20Supported\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"executor\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"feeToAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"erc20\",\"type\":\"address\"}],\"name\":\"removeERC20Support\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"renounceOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_feeToAddress\",\"type\":\"address\"}],\"name\":\"setFeeToAddress\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"updateExecutor\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}],\"devdoc\":{\"kind\":\"dev\",\"methods\":{\"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. Can only be called by the current owner. NOTE: Renouncing ownership will leave the contract without an owner, thereby disabling 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.\"},\"updateExecutor(address)\":{\"details\":\"update executor\"}},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"project:/contracts/market/MallBase.sol\":\"MallBase\"},\"evmVersion\":\"london\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"@openzeppelin/contracts/access/Ownable.sol\":{\"keccak256\":\"0xba43b97fba0d32eb4254f6a5a297b39a19a247082a02d6e69349e071e2946218\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://fc980984badf3984b6303b377711220e067722bbd6a135b24669ff5069ef9f32\",\"dweb:/ipfs/QmPHXMSXj99XjSVM21YsY6aNtLLjLVXDbyN76J5HQYvvrz\"]},\"@openzeppelin/contracts/utils/Context.sol\":{\"keccak256\":\"0xe2e337e6dde9ef6b680e07338c493ebea1b5fd09b43424112868e9cc1706bca7\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://6df0ddf21ce9f58271bdfaa85cde98b200ef242a05a3f85c2bc10a8294800a92\",\"dweb:/ipfs/QmRK2Y5Yc6BK7tGKkgsgn3aJEQGi5aakeSPZvS65PV8Xp3\"]},\"project:/contracts/market/MallBase.sol\":{\"keccak256\":\"0xed857b8b9281b1594c81896d61271093a6470de4bae6791a2f5bf9058c7d93ec\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://d5e235659046d2476d9101597cbe3eed54f361450a650d368bdc919c33d0641a\",\"dweb:/ipfs/QmNLuBDM2pzQqsGgo5Na4Jh2qqLHbJPSdFWisqJUBq5X4e\"]}},\"version\":1}",
"bytecode": "0x",
"deployedBytecode": "0x",
"immutableReferences": {},
"generatedSources": [],
"deployedGeneratedSources": [],
"sourceMap": "",
"deployedSourceMap": "",
"source": "// SPDX-License-Identifier: MIT\r\npragma solidity 0.8.10;\r\n\r\nimport \"@openzeppelin/contracts/access/Ownable.sol\";\r\n\r\nabstract contract MallBase is Ownable {\r\n address public executor;\r\n // Address to receive transaction fee\r\n address public feeToAddress;\r\n\r\n mapping(address => bool) public erc20Supported;\r\n event AddERC20Suppout(address erc20);\r\n event RemoveERC20Suppout(address erc20);\r\n\r\n function addERC20Support(address erc20) external onlyOwner {\r\n require(erc20 != address(0), \"ERC20 address is zero\");\r\n erc20Supported[erc20] = true;\r\n emit AddERC20Suppout(erc20);\r\n }\r\n\r\n function removeERC20Support(address erc20) external onlyOwner {\r\n erc20Supported[erc20] = false;\r\n emit RemoveERC20Suppout(erc20);\r\n }\r\n\r\n /**\r\n * @dev update executor\r\n */\r\n function updateExecutor(address account) external onlyOwner {\r\n require(account != address(0), \"address can not be zero\");\r\n executor = account;\r\n }\r\n\r\n function setFeeToAddress(address _feeToAddress) external onlyOwner {\r\n require(\r\n _feeToAddress != address(0),\r\n \"fee received address can not be zero\"\r\n );\r\n feeToAddress = _feeToAddress;\r\n }\r\n}\r\n",
"sourcePath": "D:\\res\\CEBG\\becrypto\\contracts\\market\\MallBase.sol",
"ast": {
"absolutePath": "project:/contracts/market/MallBase.sol",
"exportedSymbols": {
"Context": [
6470
],
"MallBase": [
15249
],
"Ownable": [
651
]
},
"id": 15250,
"license": "MIT",
"nodeType": "SourceUnit",
"nodes": [
{
"id": 15138,
"literals": [
"solidity",
"0.8",
".10"
],
"nodeType": "PragmaDirective",
"src": "33:23:61"
},
{
"absolutePath": "@openzeppelin/contracts/access/Ownable.sol",
"file": "@openzeppelin/contracts/access/Ownable.sol",
"id": 15139,
"nameLocation": "-1:-1:-1",
"nodeType": "ImportDirective",
"scope": 15250,
"sourceUnit": 652,
"src": "60:52:61",
"symbolAliases": [],
"unitAlias": ""
},
{
"abstract": true,
"baseContracts": [
{
"baseName": {
"id": 15140,
"name": "Ownable",
"nodeType": "IdentifierPath",
"referencedDeclaration": 651,
"src": "146:7:61"
},
"id": 15141,
"nodeType": "InheritanceSpecifier",
"src": "146:7:61"
}
],
"canonicalName": "MallBase",
"contractDependencies": [],
"contractKind": "contract",
"fullyImplemented": true,
"id": 15249,
"linearizedBaseContracts": [
15249,
651,
6470
],
"name": "MallBase",
"nameLocation": "134:8:61",
"nodeType": "ContractDefinition",
"nodes": [
{
"constant": false,
"functionSelector": "c34c08e5",
"id": 15143,
"mutability": "mutable",
"name": "executor",
"nameLocation": "174:8:61",
"nodeType": "VariableDeclaration",
"scope": 15249,
"src": "159:23:61",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 15142,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "159:7:61",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"visibility": "public"
},
{
"constant": false,
"functionSelector": "083d80f9",
"id": 15145,
"mutability": "mutable",
"name": "feeToAddress",
"nameLocation": "243:12:61",
"nodeType": "VariableDeclaration",
"scope": 15249,
"src": "228:27:61",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 15144,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "228:7:61",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"visibility": "public"
},
{
"constant": false,
"functionSelector": "9017f79e",
"id": 15149,
"mutability": "mutable",
"name": "erc20Supported",
"nameLocation": "294:14:61",
"nodeType": "VariableDeclaration",
"scope": 15249,
"src": "262:46:61",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_bool_$",
"typeString": "mapping(address => bool)"
},
"typeName": {
"id": 15148,
"keyType": {
"id": 15146,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "270:7:61",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "Mapping",
"src": "262:24:61",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_bool_$",
"typeString": "mapping(address => bool)"
},
"valueType": {
"id": 15147,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "281:4:61",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
},
"visibility": "public"
},
{
"anonymous": false,
"id": 15153,
"name": "AddERC20Suppout",
"nameLocation": "319:15:61",
"nodeType": "EventDefinition",
"parameters": {
"id": 15152,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 15151,
"indexed": false,
"mutability": "mutable",
"name": "erc20",
"nameLocation": "343:5:61",
"nodeType": "VariableDeclaration",
"scope": 15153,
"src": "335:13:61",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 15150,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "335:7:61",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"visibility": "internal"
}
],
"src": "334:15:61"
},
"src": "313:37:61"
},
{
"anonymous": false,
"id": 15157,
"name": "RemoveERC20Suppout",
"nameLocation": "360:18:61",
"nodeType": "EventDefinition",
"parameters": {
"id": 15156,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 15155,
"indexed": false,
"mutability": "mutable",
"name": "erc20",
"nameLocation": "387:5:61",
"nodeType": "VariableDeclaration",
"scope": 15157,
"src": "379:13:61",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 15154,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "379:7:61",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"visibility": "internal"
}
],
"src": "378:15:61"
},
"src": "354:40:61"
},
{
"body": {
"id": 15184,
"nodeType": "Block",
"src": "459:135:61",
"statements": [
{
"expression": {
"arguments": [
{
"commonType": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"id": 15170,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"id": 15165,
"name": "erc20",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 15159,
"src": "474:5:61",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "BinaryOperation",
"operator": "!=",
"rightExpression": {
"arguments": [
{
"hexValue": "30",
"id": 15168,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "491:1:61",
"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": 15167,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "483:7:61",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_address_$",
"typeString": "type(address)"
},
"typeName": {
"id": 15166,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "483:7:61",
"typeDescriptions": {}
}
},
"id": 15169,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "483:10:61",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"src": "474:19:61",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"hexValue": "45524332302061646472657373206973207a65726f",
"id": 15171,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "495:23:61",
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_3d1d4adcc59749b5d042ef099480f6d549cd45fbb220ca097fe0a691a2a937ef",
"typeString": "literal_string \"ERC20 address is zero\""
},
"value": "ERC20 address is zero"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
},
{
"typeIdentifier": "t_stringliteral_3d1d4adcc59749b5d042ef099480f6d549cd45fbb220ca097fe0a691a2a937ef",
"typeString": "literal_string \"ERC20 address is zero\""
}
],
"id": 15164,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
4294967278,
4294967278
],
"referencedDeclaration": 4294967278,
"src": "466:7:61",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 15172,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "466:53:61",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 15173,
"nodeType": "ExpressionStatement",
"src": "466:53:61"
},
{
"expression": {
"id": 15178,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"baseExpression": {
"id": 15174,
"name": "erc20Supported",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 15149,
"src": "526:14:61",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_bool_$",
"typeString": "mapping(address => bool)"
}
},
"id": 15176,
"indexExpression": {
"id": 15175,
"name": "erc20",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 15159,
"src": "541:5:61",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": true,
"nodeType": "IndexAccess",
"src": "526:21:61",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"hexValue": "74727565",
"id": 15177,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "bool",
"lValueRequested": false,
"nodeType": "Literal",
"src": "550:4:61",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"value": "true"
},
"src": "526:28:61",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"id": 15179,
"nodeType": "ExpressionStatement",
"src": "526:28:61"
},
{
"eventCall": {
"arguments": [
{
"id": 15181,
"name": "erc20",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 15159,
"src": "582:5:61",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 15180,
"name": "AddERC20Suppout",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 15153,
"src": "566:15:61",
"typeDescriptions": {
"typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$",
"typeString": "function (address)"
}
},
"id": 15182,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "566:22:61",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 15183,
"nodeType": "EmitStatement",
"src": "561:27:61"
}
]
},
"functionSelector": "b9d2df61",
"id": 15185,
"implemented": true,
"kind": "function",
"modifiers": [
{
"id": 15162,
"kind": "modifierInvocation",
"modifierName": {
"id": 15161,
"name": "onlyOwner",
"nodeType": "IdentifierPath",
"referencedDeclaration": 570,
"src": "449:9:61"
},
"nodeType": "ModifierInvocation",
"src": "449:9:61"
}
],
"name": "addERC20Support",
"nameLocation": "409:15:61",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 15160,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 15159,
"mutability": "mutable",
"name": "erc20",
"nameLocation": "433:5:61",
"nodeType": "VariableDeclaration",
"scope": 15185,
"src": "425:13:61",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 15158,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "425:7:61",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"visibility": "internal"
}
],
"src": "424:15:61"
},
"returnParameters": {
"id": 15163,
"nodeType": "ParameterList",
"parameters": [],
"src": "459:0:61"
},
"scope": 15249,
"src": "400:194:61",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"body": {
"id": 15202,
"nodeType": "Block",
"src": "662:79:61",
"statements": [
{
"expression": {
"id": 15196,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"baseExpression": {
"id": 15192,
"name": "erc20Supported",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 15149,
"src": "669:14:61",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_bool_$",
"typeString": "mapping(address => bool)"
}
},
"id": 15194,
"indexExpression": {
"id": 15193,
"name": "erc20",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 15187,
"src": "684:5:61",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": true,
"nodeType": "IndexAccess",
"src": "669:21:61",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"hexValue": "66616c7365",
"id": 15195,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "bool",
"lValueRequested": false,
"nodeType": "Literal",
"src": "693:5:61",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"value": "false"
},
"src": "669:29:61",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"id": 15197,
"nodeType": "ExpressionStatement",
"src": "669:29:61"
},
{
"eventCall": {
"arguments": [
{
"id": 15199,
"name": "erc20",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 15187,
"src": "729:5:61",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 15198,
"name": "RemoveERC20Suppout",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 15157,
"src": "710:18:61",
"typeDescriptions": {
"typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$",
"typeString": "function (address)"
}
},
"id": 15200,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "710:25:61",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 15201,
"nodeType": "EmitStatement",
"src": "705:30:61"
}
]
},
"functionSelector": "fdf397ee",
"id": 15203,
"implemented": true,
"kind": "function",
"modifiers": [
{
"id": 15190,
"kind": "modifierInvocation",
"modifierName": {
"id": 15189,
"name": "onlyOwner",
"nodeType": "IdentifierPath",
"referencedDeclaration": 570,
"src": "652:9:61"
},
"nodeType": "ModifierInvocation",
"src": "652:9:61"
}
],
"name": "removeERC20Support",
"nameLocation": "609:18:61",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 15188,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 15187,
"mutability": "mutable",
"name": "erc20",
"nameLocation": "636:5:61",
"nodeType": "VariableDeclaration",
"scope": 15203,
"src": "628:13:61",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 15186,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "628:7:61",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"visibility": "internal"
}
],
"src": "627:15:61"
},
"returnParameters": {
"id": 15191,
"nodeType": "ParameterList",
"parameters": [],
"src": "662:0:61"
},
"scope": 15249,
"src": "600:141:61",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"body": {
"id": 15225,
"nodeType": "Block",
"src": "848:95:61",
"statements": [
{
"expression": {
"arguments": [
{
"commonType": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"id": 15217,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"id": 15212,
"name": "account",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 15206,
"src": "863:7:61",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "BinaryOperation",
"operator": "!=",
"rightExpression": {
"arguments": [
{
"hexValue": "30",
"id": 15215,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "882:1:61",
"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": 15214,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "874:7:61",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_address_$",
"typeString": "type(address)"
},
"typeName": {
"id": 15213,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "874:7:61",
"typeDescriptions": {}
}
},
"id": 15216,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "874:10:61",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"src": "863:21:61",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"hexValue": "616464726573732063616e206e6f74206265207a65726f",
"id": 15218,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "886:25:61",
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_8acc3ee93e123270baeb206c430cf52b6f082d016072bd6f96b9fec703556e4c",
"typeString": "literal_string \"address can not be zero\""
},
"value": "address can not be zero"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
},
{
"typeIdentifier": "t_stringliteral_8acc3ee93e123270baeb206c430cf52b6f082d016072bd6f96b9fec703556e4c",
"typeString": "literal_string \"address can not be zero\""
}
],
"id": 15211,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
4294967278,
4294967278
],
"referencedDeclaration": 4294967278,
"src": "855:7:61",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 15219,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "855:57:61",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 15220,
"nodeType": "ExpressionStatement",
"src": "855:57:61"
},
{
"expression": {
"id": 15223,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"id": 15221,
"name": "executor",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 15143,
"src": "919:8:61",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"id": 15222,
"name": "account",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 15206,
"src": "930:7:61",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"src": "919:18:61",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"id": 15224,
"nodeType": "ExpressionStatement",
"src": "919:18:61"
}
]
},
"documentation": {
"id": 15204,
"nodeType": "StructuredDocumentation",
"src": "747:37:61",
"text": " @dev update executor"
},
"functionSelector": "74936c16",
"id": 15226,
"implemented": true,
"kind": "function",
"modifiers": [
{
"id": 15209,
"kind": "modifierInvocation",
"modifierName": {
"id": 15208,
"name": "onlyOwner",
"nodeType": "IdentifierPath",
"referencedDeclaration": 570,
"src": "838:9:61"
},
"nodeType": "ModifierInvocation",
"src": "838:9:61"
}
],
"name": "updateExecutor",
"nameLocation": "797:14:61",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 15207,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 15206,
"mutability": "mutable",
"name": "account",
"nameLocation": "820:7:61",
"nodeType": "VariableDeclaration",
"scope": 15226,
"src": "812:15:61",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 15205,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "812:7:61",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"visibility": "internal"
}
],
"src": "811:17:61"
},
"returnParameters": {
"id": 15210,
"nodeType": "ParameterList",
"parameters": [],
"src": "848:0:61"
},
"scope": 15249,
"src": "788:155:61",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"body": {
"id": 15247,
"nodeType": "Block",
"src": "1016:145:61",
"statements": [
{
"expression": {
"arguments": [
{
"commonType": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"id": 15239,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"id": 15234,
"name": "_feeToAddress",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 15228,
"src": "1039:13:61",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "BinaryOperation",
"operator": "!=",
"rightExpression": {
"arguments": [
{
"hexValue": "30",
"id": 15237,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "1064:1:61",
"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": 15236,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "1056:7:61",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_address_$",
"typeString": "type(address)"
},
"typeName": {
"id": 15235,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "1056:7:61",
"typeDescriptions": {}
}
},
"id": 15238,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "1056:10:61",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"src": "1039:27:61",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"hexValue": "66656520726563656976656420616464726573732063616e206e6f74206265207a65726f",
"id": 15240,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "1075:38:61",
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_aaa625db430dfb3ad2fa62eaddd511a6cd8de860cee36054f7986cfa0debb924",
"typeString": "literal_string \"fee received address can not be zero\""
},
"value": "fee received address can not be zero"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
},
{
"typeIdentifier": "t_stringliteral_aaa625db430dfb3ad2fa62eaddd511a6cd8de860cee36054f7986cfa0debb924",
"typeString": "literal_string \"fee received address can not be zero\""
}
],
"id": 15233,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
4294967278,
4294967278
],
"referencedDeclaration": 4294967278,
"src": "1023:7:61",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 15241,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "1023:97:61",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 15242,
"nodeType": "ExpressionStatement",
"src": "1023:97:61"
},
{
"expression": {
"id": 15245,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"id": 15243,
"name": "feeToAddress",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 15145,
"src": "1127:12:61",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"id": 15244,
"name": "_feeToAddress",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 15228,
"src": "1142:13:61",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"src": "1127:28:61",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"id": 15246,
"nodeType": "ExpressionStatement",
"src": "1127:28:61"
}
]
},
"functionSelector": "580bb9a5",
"id": 15248,
"implemented": true,
"kind": "function",
"modifiers": [
{
"id": 15231,
"kind": "modifierInvocation",
"modifierName": {
"id": 15230,
"name": "onlyOwner",
"nodeType": "IdentifierPath",
"referencedDeclaration": 570,
"src": "1006:9:61"
},
"nodeType": "ModifierInvocation",
"src": "1006:9:61"
}
],
"name": "setFeeToAddress",
"nameLocation": "958:15:61",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 15229,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 15228,
"mutability": "mutable",
"name": "_feeToAddress",
"nameLocation": "982:13:61",
"nodeType": "VariableDeclaration",
"scope": 15248,
"src": "974:21:61",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 15227,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "974:7:61",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"visibility": "internal"
}
],
"src": "973:23:61"
},
"returnParameters": {
"id": 15232,
"nodeType": "ParameterList",
"parameters": [],
"src": "1016:0:61"
},
"scope": 15249,
"src": "949:212:61",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
}
],
"scope": 15250,
"src": "116:1048:61",
"usedErrors": []
}
],
"src": "33:1133:61"
},
"compiler": {
"name": "solc",
"version": "0.8.10+commit.fc410830.Emscripten.clang"
},
"networks": {},
"schemaVersion": "3.4.14",
"updatedAt": "2023-09-05T06:06:15.996Z",
"devdoc": {
"kind": "dev",
"methods": {
"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. Can only be called by the current owner. NOTE: Renouncing ownership will leave the contract without an owner, thereby disabling 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."
},
"updateExecutor(address)": {
"details": "update executor"
}
},
"version": 1
},
"userdoc": {
"kind": "user",
"methods": {},
"version": 1
}
}