Treasury Contract는 에어드랍 실행을 주관하는 컨트랙트입니다. 권한을 가진 Operator는 Treasury Contract를 통하여 에어드랍을 설정하고 집행할 수 있습니다.
Events, Read-Only Functions, and State-Changing Functions
Events
ChangeCreationFee
event ChangeCreationFee(uint fee);
생성 수수료(KSP) 변경 시 발생되는 이벤트
SetOperator
event SetOperator(address operator, bool valid);
CreateDistribution
event CreateDistribution(address operator, address token, uint totalAmount, uint blockAmount, uint blockNumber, address[] targets, uint[] rates);
RemoveDistribution
event RemoveDistribution(address operator, address token);
Deposit
event Deposit(address operator, address token, uint amount);
RefixBlockAmount
event RefixBlockAmount(address operator, address token, uint blockAmount);
RefixDistributionRate
event RefixDistributionRate(address operator, address token, address[] targets, uint[] rates);
RefixDistributionRate 이벤트
Read-Only Functions
distributionCount
distributionEntries
mapping(address => mapping(uint => address))
distributionOperator
mapping (address => address)
Distribution 별 Operator 주소
fee
owner
State-Changing Functions
changeCreationFee
function changeCreationFee(uint _fee) public
Distribution 생성 수수료 변경 함수
claim
function claim(address target) public
createKlayDistribution
function createKlayDistribution(uint blockAmount, uint blockNumber, address[] memory targets, uint[] memory rates) public payable
createTokenDistribution
function createTokenDistribution(address token, uint amount, uint blockAmount, uint blockNumber, address[] memory targets, uint[] memory rates) public
depositKlay
function depositKlay() public payable
depositToken
function depositToken(address token, uint amount) public
refixBlockAmount
function refixBlockAmount(address token, uint blockAmount) public
refixDistributionRate
function refixDistributionRate(address token, address[] memory targets, uint[] memory rates) public
removeDistribution
function removeDistribution(address operator, address token) public
Distribution.removeDistribution() 함수 호출