Module Data_structures.OrderBook

Lock-free order book data structure

type price = float
type quantity = float
type side =
  1. | Bid
  2. | Ask
type t
val create : table_size:int -> t
val add_order : t -> side -> price -> quantity -> unit
val get_best_bid : t -> price option
val get_best_ask : t -> price option
val get_spread : t -> price option
val get_midprice : t -> price option