EpochCapture
EpochCapture
A middleware extension that captures timestamps based on epochs
Epochs are fixed time periods starting from a base timestamp
Methods
getEpochStart
function getEpochStart(
uint48 epoch
) public view returns (uint48)
Returns the start timestamp for a given epoch
Parameters
Name | Type | Description |
---|---|---|
epoch | uint48 | The epoch number |
Returns
Name | Type | Description |
---|---|---|
uint48 | The start timestamp |
getCurrentEpoch
function getCurrentEpoch() public view returns (uint48)
Returns the current epoch number
Returns
Name | Type | Description |
---|---|---|
uint48 | The current epoch |
getEpochDuration
function getEpochDuration() public view returns (uint48)
Returns the duration of each epoch
Returns
Name | Type | Description |
---|---|---|
uint48 | The duration of each epoch |