Lybra V2 Technical Whitepaper
  • Overview
    • The Lybra V2 Smart Contracts
  • Core
    • eUSD
    • peUSD Token
    • LybraConfigurator
    • Pool
      • Overview
      • Base
        • LybraEUSDVaultBase
        • LybraPeUSDVaultBase
      • Derived Contracts
        • LybraStETHDepositVault
        • LybraWstETHVault
        • LybraWBETHVault
        • LybraRETHVault
  • Governance
    • Overview
    • Token
    • Timelock
    • Access
    • Process
      • Propose
      • Vote
      • Queue
      • Execute
      • Cancel
    • Example
    • API
    • Glossary
    • Miner
      • EUSDMiningIncentives
      • esLBRBoost
      • ProtocolRewardsPool
      • StakingRewardsV2
Powered by GitBook
On this page
  1. Governance
  2. Miner

StakingRewardsV2

A contract that enables users to stake tokens and earn rewards based on the staked amounts and durations.

Functions

stake

function stake(uint256 _amount) external

Allows users to stake a specified amount of tokens.

Parameter
Type
Description

_amount

uint256

The amount of tokens to stake.

withdraw

function withdraw(uint256 _amount) external

Allows users to withdraw a specified amount of staked tokens.

Parameter
Type
Description

_amount

uint256

The amount of tokens to withdraw.

getBoost

function getBoost(address _account) public view returns (uint256)

Returns the boost factor for a given user's address.

Parameter
Type
Description

_account

address

The user's address.

earned

function earned(address _account) public view returns (uint256)

Calculates and returns the earned rewards for a user.

Parameter
Type
Description

_account

address

The user's address.

getReward

function getReward() external

Allows users to claim their earned rewards.

PreviousProtocolRewardsPool

Last updated 1 year ago