{
    "Function": "checkBalance",
    "File": "contracts/libraries/StrategyLibrary.sol",
    "Parent Contracts": [],
    "High-Level Calls": [
        "IStrategy",
        "SafeMath",
        "SafeMath"
    ],
    "Internal Calls": [
        "amountOutOfBalance",
        "require(bool,string)"
    ],
    "Library Calls": [
        "div",
        "mul"
    ],
    "Low-Level Calls": [],
    "Code": "function checkBalance(address strategy, uint256 balanceBefore, uint256 total, int256[] memory estimates) public view {\n        uint256 balanceAfter = amountOutOfBalance(strategy, total, estimates);\n        if (balanceAfter > uint256(10**18).mul(IStrategy(strategy).rebalanceThreshold()).div(uint256(DIVISOR)))\n            require(balanceAfter <= balanceBefore, \"Lost balance\");\n    }"
}