Skip to main content

IGhoDiscountRateStrategy

Defines the basic interface of the GhoDiscountRateStrategy.

This page shows the view methods within the IGhoDiscountRateStrategy interface. The source code is available on GitHub.

View Methods

calculateDiscountRate

function calculateDiscountRate(
uint256 debtBalance,
uint256 discountTokenBalance
) external view returns (uint256)

Calculates the discount rate depending on the debt and discount token balances.

Input Parameters:

NameTypeDescription
debtBalanceuint256The debt balance of the user
discountTokenBalanceuint256The discount token balance of the user

Return Values:

TypeDescription
uint256The discount rate, as a percentage - the maximum can be 10000 = 100.00%