Staking Protocolinterfaces

ICampaignTimesFacet

It defines the basic interface of CampaignTimes facets.

initCampaignTimesFacet

function initCampaignTimesFacet(bytes initCampaignTimesData) external

Initialization function.

The structure and content of initCampaignTimesData are implementation specific.

Parameters

NameTypeDescription
initCampaignTimesDatabytesThe ABI-encoded initialization data.

setCampaignTimesData

function setCampaignTimesData(uint256 campaignId, bytes campaignTimesData) external

Setter function for configuring essential timestamps for campaigns.

Setter functions are executed during the creation process of campaigns. The structure and content of campaignTimesData are implementation specific.

Parameters

NameTypeDescription
campaignIduint256The unique identifier of the targeted staking campaign.
campaignTimesDatabytesThe ABI-encoded configuration data.

checkCampaignTimesOnStake

function checkCampaignTimesOnStake(uint256 campaignId) external view returns (uint256)

Checks whether the targeted campaign is currently within the allowed time period for a stake or restake operation.

Parameters

NameTypeDescription
campaignIduint256The unique identifier of the targeted staking campaign.

Return Values

NameTypeDescription
[0]uint256The active start timestamp of the stake (or restake) operation.

On this page