pub fn base_to_quote(
base_amount: u128,
tick: i16,
rounding: RoundingDirection,
) -> Option<u128>Expand description
Convert base token amount to quote token amount at a given tick.
Formula: quote_amount = (base_amount * price) / PRICE_SCALE
Uses U256 for intermediate multiplication to prevent overflow.
§Arguments
base_amount- Amount of base tokenstick- Price tickrounding- Rounding direction
§Returns
Quote token amount, or None if result exceeds u128