#[no_mangle]
pub extern "C" fn orderbook_deltas_new(
instrument_id: InstrumentId,
deltas: &CVec,
) -> OrderBookDeltas_API
Expand description
Creates a new OrderBookDeltas
instance from a CVec
of OrderBookDelta
.
ยงSafety
- The
deltas
must be a valid pointer to aCVec
containingOrderBookDelta
objects - This function clones the data pointed to by
deltas
into Rust-managed memory, then forgets the originalVec
to prevent Rust from auto-deallocating it - The caller is responsible for managing the memory of
deltas
(including its deallocation) to avoid memory leaks