{
    "Function": "previewDeposit",
    "File": "src/InvestmentManager.sol",
    "Parent Contracts": [
        "src/util/Auth.sol"
    ],
    "High-Level Calls": [],
    "Internal Calls": [
        "calculateDepositPrice",
        "_calculateTrancheTokenAmount",
        "_toUint128"
    ],
    "Library Calls": [],
    "Low-Level Calls": [],
    "Code": "function previewDeposit(address user, address liquidityPool, uint256 _currencyAmount)\n        public\n        view\n        returns (uint256 trancheTokenAmount)\n    {\n        uint128 currencyAmount = _toUint128(_currencyAmount);\n        uint256 depositPrice = calculateDepositPrice(user, liquidityPool);\n        if (depositPrice == 0) return 0;\n\n        trancheTokenAmount = uint256(_calculateTrancheTokenAmount(currencyAmount, liquidityPool, depositPrice));\n    }"
}