Function: _collateralizedMint(PoolParams poolParams, uint256 shares, address payer, address longRecipient, address shortRecipient)
This function is used to mint long and short tokens for a pool.
Inputs
poolParamsControl: Arbitrary.
Constraints: None.
Impact: Pool parameters.
sharesControl: Arbitrary.
Constraints: None.
Impact: Amount of shares.
payerControl: Arbitrary.
Constraints: None.
Impact: Address of the payer of collateral.
longRecipientControl: Arbitrary.
Constraints: None.
Impact: Address of the recipient of long tokens.
shortRecipientControl: Arbitrary.
Constraints: None.
Impact: Address of the recipient of short tokens.
Branches and code coverage
Intended branches
Calculates the collateral amount using the pool parameters.
Transfers the collateral from the payer to the contract.
Mints
shareslong and short tokens to the respective recipients.
Negative behavior
Reverts if the pool has already ended.