GNSTriggerRewards
Facet #6: Trigger rewards
constructor
initializeTriggerRewards
Initializes parameters for trigger rewards facet
Parameters
Name
Type
Description
_timeoutBlocks
uint16
blocks after which a trigger times out
updateTriggerTimeoutBlocks
Updates the blocks after which a trigger times out
Parameters
Name
Type
Description
_timeoutBlocks
uint16
blocks after which a trigger times out
distributeTriggerReward
Distributes GNS rewards to oracles for a specific trigger
Parameters
Name
Type
Description
_rewardGns
uint256
total GNS reward to be distributed among oracles
claimPendingTriggerRewards
Claims pending GNS trigger rewards for the caller
Parameters
Name
Type
Description
_oracle
address
address of the oracle
getTriggerTimeoutBlocks
Returns current triggerTimeoutBlocks value
hasActiveOrder
Checks if an order is active (exists and has not timed out)
Parameters
Name
Type
Description
_orderBlock
uint256
block number of the order
getTriggerPendingRewardsGns
Returns the pending GNS trigger rewards for an oracle
Parameters
Name
Type
Description
_oracle
address
address of the oracle