pub fn parse_trade(
msg: &BinanceFuturesTradeMsg,
instrument: &InstrumentAny,
ts_init: UnixNanos,
) -> BinanceWsResult<Option<TradeTick>>Expand description
Parses a raw trade message into a TradeTick.
Returns None for insurance fund, ADL, and NA messages, which the aggregate trade
stream does not include. NA messages carry zero price and quantity.
ยงErrors
Returns an error if:
- The trade type is unknown.
- The price or quantity cannot be parsed, or the quantity is not positive.