BaseCollateralGauge

BaseCollateralGauge

Allocation of original rewards from third-party protocols in the Pool of collaterals

Write Methods

userHandleAction

function userHandleAction( address collateralAddress, DataTypes.M1CollateralOptType collateralOptType, address rewardOwnerUser, uint256 amountLp) external

OnlytTokencan call the method, Triggered when users borrow, repay, or liquidate

userClaimCollateralRewardsBySingleTToken

function userClaimCollateralRewardsBySingleTToken(address collateralAddress, CollateralPoolRewardTypes.UserClaimableTTokenParams memory tTokenParams) external

Users receive rewards for the pool in which that collateral asset is located, based on the collateral asset.

Struct

CollateralPoolRewardTypes.UserClaimableTTokenParams

User-claimable reward parameter structure (tToken dimension)

Call Params

userClaimCollateralRewardsByCollateral

function userClaimCollateralRewardsByCollateral(CollateralPoolRewardTypes.UserClaimableCollateralParams[] memory collateralParams) externa

The user receives, based on the collateral asset, the rewards of the pool in which that collateral asset is located.

struct

CollateralPoolRewardTypes.UserClaimableCollateralParams

User query for claimable rewards parameter structure (collateral dimension)

Call Params

userClaimAllCollateralRewards

function userClaimAllCollateralRewards() external

Receive rewards for the pool in which all collateral assets are located.

Too much collateral will be reported as an error.

View Methods

getRewards

function getRewards(address collateralAddress) external view returns (address[] memory)

Get the list of reward token owned by this pool of collateralized assets

Call Params

Return Values

getUserClaimableRewardsBySingleTToken

function getUserClaimableRewardsBySingleTToken(address user, address collateralAddress, CollateralPoolRewardTypes.UserClaimableTTokenParams[] memory tTokenParams) external view returns (CollateralPoolRewardTypes.UserClaimableTTokenResult[] memory)

Acquire based on single or multiple tToken dimensions to obtain rewards for users who can receive a pool of re-collateralized assets.

Call Params

struct

CollateralPoolRewardTypes.UserClaimableTTokenResult

Return Values

getUserClaimableRewardsByCollateral

function getUserClaimableRewardsByCollateral(address user, CollateralPoolRewardTypes.UserClaimableCollateralParams[] memory collateralParams) external view returns (CollateralPoolRewardTypes.UserClaimableCollateralResult[] memory)

Based on single or multiple collateral dimension acquisition, get the rewards that users can receive to change the pool of collateral assets.

Call Params

struct

CollateralPoolRewardTypes.UserClaimableCollateralResult

Return Values

getUserAllClaimableRewards

function getUserAllClaimableRewards(address user) external view returns (CollateralPoolRewardTypes.UserClaimableCollateralResult[] memory)

Acquiring users can receive rewards for changing the collateral asset pool.

Call Params

Return Values

Last updated