Staking Protocolinterfaces
ITransferRewardFacet
It defines the basic interface of TransferReward facets.
initTransferRewardFacet
Initialization function.
The structure and content of transferRewardData
are implementation specific.
Parameters
Name | Type | Description |
---|---|---|
transferRewardData | bytes | The ABI-encoded initialization data. |
setCampaignTransferRewards
Setter function for configuring the reward packet for the specified staking campaign.
Setter functions are executed during the creation process of campaigns.
The structure and content of campaignTransferRewardsData
are implementation specific.
Parameters
Name | Type | Description |
---|---|---|
campaignId | uint256 | The unique identifier of the targeted staking campaign. |
campaignTransferRewardsData | bytes | The ABI-encoded data containing the reward packet configuration. |
transferReward
Transfers the specified amount of a given campaign's reward packets from the from
address
to the to
address.
Parameters
Name | Type | Description |
---|---|---|
campaignId | uint256 | The unique identifier of the targeted staking campaign. |
from | address | The address from which the assets encapsulated by the specified number of reward packets to be transferred. |
to | address | The address to receive the assets encapsulated by the specified number of reward packets. |
amountOfPackets | uint256 | The number of reward packets to account for. |