238 lines
15 KiB
JSON
238 lines
15 KiB
JSON
{
|
|
"_format": "hh-sol-artifact-1",
|
|
"contractName": "RewardDistributor",
|
|
"sourceName": "contracts/staking/RewardDistributor.sol",
|
|
"abi": [
|
|
{
|
|
"inputs": [
|
|
{
|
|
"internalType": "address",
|
|
"name": "_rewardToken",
|
|
"type": "address"
|
|
},
|
|
{
|
|
"internalType": "address",
|
|
"name": "_rewardTracker",
|
|
"type": "address"
|
|
}
|
|
],
|
|
"stateMutability": "nonpayable",
|
|
"type": "constructor"
|
|
},
|
|
{
|
|
"anonymous": false,
|
|
"inputs": [
|
|
{
|
|
"indexed": false,
|
|
"internalType": "uint256",
|
|
"name": "amount",
|
|
"type": "uint256"
|
|
}
|
|
],
|
|
"name": "Distribute",
|
|
"type": "event"
|
|
},
|
|
{
|
|
"anonymous": false,
|
|
"inputs": [
|
|
{
|
|
"indexed": false,
|
|
"internalType": "uint256",
|
|
"name": "amount",
|
|
"type": "uint256"
|
|
}
|
|
],
|
|
"name": "TokensPerIntervalChange",
|
|
"type": "event"
|
|
},
|
|
{
|
|
"inputs": [],
|
|
"name": "admin",
|
|
"outputs": [
|
|
{
|
|
"internalType": "address",
|
|
"name": "",
|
|
"type": "address"
|
|
}
|
|
],
|
|
"stateMutability": "view",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [
|
|
{
|
|
"internalType": "uint256",
|
|
"name": "_amount",
|
|
"type": "uint256"
|
|
},
|
|
{
|
|
"internalType": "uint256",
|
|
"name": "_decimals",
|
|
"type": "uint256"
|
|
}
|
|
],
|
|
"name": "distribute",
|
|
"outputs": [
|
|
{
|
|
"internalType": "uint256",
|
|
"name": "",
|
|
"type": "uint256"
|
|
}
|
|
],
|
|
"stateMutability": "nonpayable",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [],
|
|
"name": "gov",
|
|
"outputs": [
|
|
{
|
|
"internalType": "address",
|
|
"name": "",
|
|
"type": "address"
|
|
}
|
|
],
|
|
"stateMutability": "view",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [],
|
|
"name": "lastDistributionTime",
|
|
"outputs": [
|
|
{
|
|
"internalType": "uint256",
|
|
"name": "",
|
|
"type": "uint256"
|
|
}
|
|
],
|
|
"stateMutability": "view",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [],
|
|
"name": "pendingRewards",
|
|
"outputs": [
|
|
{
|
|
"internalType": "uint256",
|
|
"name": "",
|
|
"type": "uint256"
|
|
}
|
|
],
|
|
"stateMutability": "view",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [],
|
|
"name": "rewardToken",
|
|
"outputs": [
|
|
{
|
|
"internalType": "address",
|
|
"name": "",
|
|
"type": "address"
|
|
}
|
|
],
|
|
"stateMutability": "view",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [],
|
|
"name": "rewardTracker",
|
|
"outputs": [
|
|
{
|
|
"internalType": "address",
|
|
"name": "",
|
|
"type": "address"
|
|
}
|
|
],
|
|
"stateMutability": "view",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [
|
|
{
|
|
"internalType": "address",
|
|
"name": "_admin",
|
|
"type": "address"
|
|
}
|
|
],
|
|
"name": "setAdmin",
|
|
"outputs": [],
|
|
"stateMutability": "nonpayable",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [
|
|
{
|
|
"internalType": "address",
|
|
"name": "_gov",
|
|
"type": "address"
|
|
}
|
|
],
|
|
"name": "setGov",
|
|
"outputs": [],
|
|
"stateMutability": "nonpayable",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [
|
|
{
|
|
"internalType": "uint256",
|
|
"name": "_amount",
|
|
"type": "uint256"
|
|
}
|
|
],
|
|
"name": "setTokensPerInterval",
|
|
"outputs": [],
|
|
"stateMutability": "nonpayable",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [],
|
|
"name": "tokensPerInterval",
|
|
"outputs": [
|
|
{
|
|
"internalType": "uint256",
|
|
"name": "",
|
|
"type": "uint256"
|
|
}
|
|
],
|
|
"stateMutability": "view",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [],
|
|
"name": "updateLastDistributionTime",
|
|
"outputs": [],
|
|
"stateMutability": "nonpayable",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [
|
|
{
|
|
"internalType": "address",
|
|
"name": "_token",
|
|
"type": "address"
|
|
},
|
|
{
|
|
"internalType": "address",
|
|
"name": "_account",
|
|
"type": "address"
|
|
},
|
|
{
|
|
"internalType": "uint256",
|
|
"name": "_amount",
|
|
"type": "uint256"
|
|
}
|
|
],
|
|
"name": "withdrawToken",
|
|
"outputs": [],
|
|
"stateMutability": "nonpayable",
|
|
"type": "function"
|
|
}
|
|
],
|
|
"bytecode": "0x6080346100a157601f610a7638819003918201601f19168301916001600160401b038311848410176100a65780849260409485528339810103126100a157610052602061004b836100bc565b92016100bc565b90600160005560018060a01b0319913383600154161760015560018060a01b0380921683600254161760025516816005541617600555339060065416176006556040516109a590816100d18239f35b600080fd5b634e487b7160e01b600052604160045260246000fd5b51906001600160a01b03821682036100a15756fe6040608081526004908136101561001557600080fd5b600091823560e01c90816301e33667146103d557816312d43a51146103ac57816318e20a03146102825781633ae6d6eb146102555781636bcb411a1461022c578163704b6c02146101dc57816375b17350146101ba5781637625391a1461019757508063a8d9362714610179578063cfad57a214610128578063eded3fda14610105578063f7c618c1146100dd5763f851a440146100b257600080fd5b346100d957816003193601126100d95760065490516001600160a01b039091168152602090f35b5080fd5b50346100d957816003193601126100d95760025490516001600160a01b039091168152602090f35b50346100d957816003193601126100d95760209061012161078c565b9051908152f35b823461017657602036600319011261017657610142610428565b600154906001600160a01b039061015c3383851614610443565b16906bffffffffffffffffffffffff60a01b161760015580f35b80fd5b50346100d957816003193601126100d9576020906003549051908152f35b8284346101765781600319360112610176575061012160209260243590356107b4565b9050346101d857826003193601126101d85760209250549051908152f35b8280fd5b8334610176576020366003190112610176576101f6610428565b6001546001600160a01b0391906102109083163314610443565b166bffffffffffffffffffffffff60a01b600654161760065580f35b5050346100d957816003193601126100d95760055490516001600160a01b039091168152602090f35b8390346100d957816003193601126100d95761027c60018060a01b03600654163314610717565b42905580f35b919050346101d85760203660031901126101d85781359160018060a01b036102af81600654163314610717565b8154156103515790849160055416803b156101d857829082855180958193630f8562c360e21b83525af1801561034757610316575b847f98dc76c39aa5a5dcb749f8750a65db3dfa1e14bcc1591a9c16a7420e5da748f8602086868160035551908152a180f35b67ffffffffffffffff829593951161033457508352918160206102e4565b634e487b7160e01b835260419052602482fd5b83513d87823e3d90fd5b506020608492519162461bcd60e51b8352820152602f60248201527f5265776172644469737472696275746f723a20696e76616c6964206c6173744460448201526e6973747269627574696f6e54696d6560881b6064820152fd5b5050346100d957816003193601126100d95760015490516001600160a01b039091168152602090f35b8334610176576060366003190112610176576103ef610428565b6001600160a01b03906024358281168103610424578261041761042194600154163314610443565b60443592166104bf565b80f35b8380fd5b600435906001600160a01b038216820361043e57565b600080fd5b1561044a57565b60405162461bcd60e51b815260206004820152601560248201527423b7bb32b93730b136329d103337b93134b23232b760591b6044820152606490fd5b90601f8019910116810190811067ffffffffffffffff8211176104a957604052565b634e487b7160e01b600052604160045260246000fd5b60405163a9059cbb60e01b60208083019182526001600160a01b03948516602484015260448084019690965294825292608082019267ffffffffffffffff929190838511838610176104a957169060c08101848110848211176104a9576040528584527f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c656460a0820152600080958192519082855af1903d15610638573d928311610624579061058e9392916040519261058188601f19601f8401160185610487565b83523d868885013e610643565b805191821591848315610600575b5050509050156105a95750565b6084906040519062461bcd60e51b82526004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6044820152691bdd081cdd58d8d9595960b21b6064820152fd5b9193818094500103126100d95782015190811515820361017657508038808461059c565b634e487b7160e01b85526041600452602485fd5b9061058e9392506060915b919290156106a55750815115610657575090565b3b156106605790565b60405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e74726163740000006044820152606490fd5b8251909150156106b85750805190602001fd5b6040519062461bcd60e51b82528160208060048301528251908160248401526000935b8285106106fe575050604492506000838284010152601f80199101168101030190fd5b84810182015186860160440152938101938593506106db565b1561071e57565b60405162461bcd60e51b815260206004820152601c60248201527f5265776172644469737472696275746f723a20666f7262696464656e000000006044820152606490fd5b8181029291811591840414171561077657565b634e487b7160e01b600052601160045260246000fd5b6004548042146107ae574203428111610776576107ab90600354610763565b90565b50600090565b60055490916001600160a01b03918216330361091c576107d261078c565b928315610913576107e7904260045584610763565b90604d811161077657600a0a9081156108fd5704906002541690604051916370a0823160e01b83523060048401526020928381602481855afa9081156108f1576000916108c4575b50821161086f5790610865817f4def474aca53bf221d07d9ab0f675b3f6d8d2494b8427271bcf43c018ef1eead949333906104bf565b604051908152a190565b60405162461bcd60e51b815260048101849052602760248201527f5265776172644469737472696275746f723a20696e73756666696369656e742060448201526662616c616e636560c81b6064820152608490fd5b908482813d83116108ea575b6108da8183610487565b810103126101765750513861082f565b503d6108d0565b6040513d6000823e3d90fd5b634e487b7160e01b600052601260045260246000fd5b50505050600090565b60405162461bcd60e51b815260206004820152602560248201527f5265776172644469737472696275746f723a20696e76616c6964206d73672e7360448201526432b73232b960d91b6064820152608490fdfea2646970667358221220143b643604569f6cbd8674d3264e614faea1394a6bb4ae34c7b1c41f479ac78364736f6c63430008130033",
|
|
"deployedBytecode": "0x6040608081526004908136101561001557600080fd5b600091823560e01c90816301e33667146103d557816312d43a51146103ac57816318e20a03146102825781633ae6d6eb146102555781636bcb411a1461022c578163704b6c02146101dc57816375b17350146101ba5781637625391a1461019757508063a8d9362714610179578063cfad57a214610128578063eded3fda14610105578063f7c618c1146100dd5763f851a440146100b257600080fd5b346100d957816003193601126100d95760065490516001600160a01b039091168152602090f35b5080fd5b50346100d957816003193601126100d95760025490516001600160a01b039091168152602090f35b50346100d957816003193601126100d95760209061012161078c565b9051908152f35b823461017657602036600319011261017657610142610428565b600154906001600160a01b039061015c3383851614610443565b16906bffffffffffffffffffffffff60a01b161760015580f35b80fd5b50346100d957816003193601126100d9576020906003549051908152f35b8284346101765781600319360112610176575061012160209260243590356107b4565b9050346101d857826003193601126101d85760209250549051908152f35b8280fd5b8334610176576020366003190112610176576101f6610428565b6001546001600160a01b0391906102109083163314610443565b166bffffffffffffffffffffffff60a01b600654161760065580f35b5050346100d957816003193601126100d95760055490516001600160a01b039091168152602090f35b8390346100d957816003193601126100d95761027c60018060a01b03600654163314610717565b42905580f35b919050346101d85760203660031901126101d85781359160018060a01b036102af81600654163314610717565b8154156103515790849160055416803b156101d857829082855180958193630f8562c360e21b83525af1801561034757610316575b847f98dc76c39aa5a5dcb749f8750a65db3dfa1e14bcc1591a9c16a7420e5da748f8602086868160035551908152a180f35b67ffffffffffffffff829593951161033457508352918160206102e4565b634e487b7160e01b835260419052602482fd5b83513d87823e3d90fd5b506020608492519162461bcd60e51b8352820152602f60248201527f5265776172644469737472696275746f723a20696e76616c6964206c6173744460448201526e6973747269627574696f6e54696d6560881b6064820152fd5b5050346100d957816003193601126100d95760015490516001600160a01b039091168152602090f35b8334610176576060366003190112610176576103ef610428565b6001600160a01b03906024358281168103610424578261041761042194600154163314610443565b60443592166104bf565b80f35b8380fd5b600435906001600160a01b038216820361043e57565b600080fd5b1561044a57565b60405162461bcd60e51b815260206004820152601560248201527423b7bb32b93730b136329d103337b93134b23232b760591b6044820152606490fd5b90601f8019910116810190811067ffffffffffffffff8211176104a957604052565b634e487b7160e01b600052604160045260246000fd5b60405163a9059cbb60e01b60208083019182526001600160a01b03948516602484015260448084019690965294825292608082019267ffffffffffffffff929190838511838610176104a957169060c08101848110848211176104a9576040528584527f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c656460a0820152600080958192519082855af1903d15610638573d928311610624579061058e9392916040519261058188601f19601f8401160185610487565b83523d868885013e610643565b805191821591848315610600575b5050509050156105a95750565b6084906040519062461bcd60e51b82526004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6044820152691bdd081cdd58d8d9595960b21b6064820152fd5b9193818094500103126100d95782015190811515820361017657508038808461059c565b634e487b7160e01b85526041600452602485fd5b9061058e9392506060915b919290156106a55750815115610657575090565b3b156106605790565b60405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e74726163740000006044820152606490fd5b8251909150156106b85750805190602001fd5b6040519062461bcd60e51b82528160208060048301528251908160248401526000935b8285106106fe575050604492506000838284010152601f80199101168101030190fd5b84810182015186860160440152938101938593506106db565b1561071e57565b60405162461bcd60e51b815260206004820152601c60248201527f5265776172644469737472696275746f723a20666f7262696464656e000000006044820152606490fd5b8181029291811591840414171561077657565b634e487b7160e01b600052601160045260246000fd5b6004548042146107ae574203428111610776576107ab90600354610763565b90565b50600090565b60055490916001600160a01b03918216330361091c576107d261078c565b928315610913576107e7904260045584610763565b90604d811161077657600a0a9081156108fd5704906002541690604051916370a0823160e01b83523060048401526020928381602481855afa9081156108f1576000916108c4575b50821161086f5790610865817f4def474aca53bf221d07d9ab0f675b3f6d8d2494b8427271bcf43c018ef1eead949333906104bf565b604051908152a190565b60405162461bcd60e51b815260048101849052602760248201527f5265776172644469737472696275746f723a20696e73756666696369656e742060448201526662616c616e636560c81b6064820152608490fd5b908482813d83116108ea575b6108da8183610487565b810103126101765750513861082f565b503d6108d0565b6040513d6000823e3d90fd5b634e487b7160e01b600052601260045260246000fd5b50505050600090565b60405162461bcd60e51b815260206004820152602560248201527f5265776172644469737472696275746f723a20696e76616c6964206d73672e7360448201526432b73232b960d91b6064820152608490fdfea2646970667358221220143b643604569f6cbd8674d3264e614faea1394a6bb4ae34c7b1c41f479ac78364736f6c63430008130033",
|
|
"linkReferences": {},
|
|
"deployedLinkReferences": {}
|
|
}
|