Contains state variables and read-only methods that can be called by anyone.
1. Functions
1.1. controller
function controller() external returns (address)
Returns controller contract address
1.2. manager
function manager() external returns (address)
Returns fund manager address
1.3. token
function token() external returns (address)
Returns fund local token address
1.4. descriptor
function descriptor() external returns (bytes)
Returns 32 bytes fund name + brief description of any length
1.5. lockPeriod
function lockPeriod() external returns (uint256)
Returns fund lock-up period
1.6. baseLine
function baseLine() external returns (uint256)
Returns fund manager fee baseline
1.7. managerFee
function managerFee() external returns (uint256)
Returns fund manager fee ratio
1.8. depositDeadline
function depositDeadline() external returns (uint256)
Returns the Countdown timestamp for fund deposit
1.9. lastDepositTime
function lastDepositTime(
address account
) external returns (uint256)
Get the latest deposit time
Parameters:
Name | Type | Description |
---|---|---|
account |
address | Target address |
1.10. totalInvestment
function totalInvestment() external returns (uint256)
Returns total investment
1.11. investmentOf
function investmentOf(
address owner
) external returns (uint256)
Get owner's investment
Parameters:
Name | Type | Description |
---|---|---|
owner |
address | User address |
1.12. assetsOfPosition
function assetsOfPosition(
uint256 poolIndex,
uint256 positionIndex
) external returns (uint256)
Get the number of assets in the specified position
Parameters:
Name | Type | Description |
---|---|---|
poolIndex |
uint256 | Pool index number |
positionIndex |
uint256 | Position index number |
1.13. assetsOfPool
function assetsOfPool(
uint256 poolIndex
) external returns (uint256)
Get the amount of assets in the specified pool
Parameters:
Name | Type | Description |
---|---|---|
poolIndex |
uint256 | Pool index number |
1.14. totalAssets
function totalAssets() external returns (uint256)
Get total assets of fund
Amount of total assets denominated in fund local token
1.15. buyPath
function buyPath(
address _token
) external returns (bytes)
The purchase path from the fund's local token to the target token
Purchasing path of target tokens conforming to uniswap v3 format.
Parameters:
Name | Type | Description |
---|---|---|
_token |
address | Target token address |
1.16. sellPath
function sellPath(
address _token
) external returns (bytes)
The selling path from the target token to the fund's local token
Selling path of target tokens conforming to uniswap v3 format
Parameters:
Name | Type | Description |
---|---|---|
_token |
address | Target token address |
1.17. pools
function pools(
uint256 index
) external returns (address)
Get pool address
Parameters:
Name | Type | Description |
---|---|---|
index |
uint256 | Pool index number |
1.18. positions
function positions(
uint256 poolIndex,
uint256 positionIndex
) external returns (bool isEmpty, int24 tickLower, int24 tickUpper)
Get position information
Since the fund needs to traverse the positions, a two-dimensional dynamic array is used to store the positions.
Parameters:
Name | Type | Description |
---|---|---|
poolIndex |
uint256 | Pool index number |
positionIndex |
uint256 | Position index number |
Return Values:
Name | Type | Description |
---|---|---|
isEmpty |
bool | Is it a empty position |
tickLower |
uint256 | tickLower Tick lower |
tickUpper |
uint256 | tickUpper Tick upper |
1.19. poolsLength
function poolsLength() external returns (uint256)
Get pool array length
1.20. positionsLength
function positionsLength(
uint256 poolIndex
) external returns (uint256)
Get the length of the position array of the pool
Parameters:
Name | Type | Description |
---|---|---|
poolIndex |
uint256 | Pool index number |