DexUserViews ​
Inherits:Variables, Structs, DexConstantsViews, DexPublicViews
Functions ​
getUserSupplyData ​
Get user supply data for a specific DEX and user
solidity
function getUserSupplyData(address dex_, address user_) public view returns (UserSupplyData memory userSupplyData_);
Parameters
Name | Type | Description |
---|---|---|
dex_ | address | The address of the DEX |
user_ | address | The address of the user |
Returns
Name | Type | Description |
---|---|---|
userSupplyData_ | UserSupplyData | Struct containing user supply data |
getUserSupplyDatas ​
Get user supply data for multiple users in a specific DEX
solidity
function getUserSupplyDatas(address dex_, address[] calldata users_)
public
view
returns (UserSupplyData[] memory userSuppliesData_);
Parameters
Name | Type | Description |
---|---|---|
dex_ | address | The address of the DEX |
users_ | address[] | Array of user addresses |
Returns
Name | Type | Description |
---|---|---|
userSuppliesData_ | UserSupplyData[] | Array of UserSupplyData structs for each user |
getUserBorrowData ​
Get user borrow data for a specific DEX and user
solidity
function getUserBorrowData(address dex_, address user_) public view returns (UserBorrowData memory userBorrowData_);
Parameters
Name | Type | Description |
---|---|---|
dex_ | address | The address of the DEX |
user_ | address | The address of the user |
Returns
Name | Type | Description |
---|---|---|
userBorrowData_ | UserBorrowData | Struct containing user borrow data |
getUserBorrowDatas ​
Get user borrow data for multiple users in a specific DEX
solidity
function getUserBorrowDatas(address dex_, address[] calldata users_)
public
view
returns (UserBorrowData[] memory userBorrowingsData_);
Parameters
Name | Type | Description |
---|---|---|
dex_ | address | The address of the DEX |
users_ | address[] | Array of user addresses |
Returns
Name | Type | Description |
---|---|---|
userBorrowingsData_ | UserBorrowData[] | Array of UserBorrowData structs for each user |
getUserBorrowSupplyDatas ​
Get both user supply and borrow data for multiple users in a specific DEX
solidity
function getUserBorrowSupplyDatas(address dex_, address[] calldata users_)
public
view
returns (UserSupplyData[] memory userSuppliesData_, UserBorrowData[] memory userBorrowingsData_);
Parameters
Name | Type | Description |
---|---|---|
dex_ | address | The address of the DEX |
users_ | address[] | Array of user addresses |
Returns
Name | Type | Description |
---|---|---|
userSuppliesData_ | UserSupplyData[] | Array of UserSupplyData structs for each user |
userBorrowingsData_ | UserBorrowData[] | Array of UserBorrowData structs for each user |