Uses of Enum Class
com.quantfinlib.orderbook.Side

Packages that use Side
Package
Description
Bar-based backtesting.
Event-driven tick-level backtesting — the level below bars, where queue position decides whether a passive order actually trades: TickBacktester replays QFLT tick files through a TickStrategy with microstructure-aware fills (market orders pay half the spread; limit orders fill on trade-through or earn fills print-by-print against a simulated queue; optional tick-size grid for real-world prices; no fills against the triggering print).
Execution strategy support: SmartOrderRouter (fee-adjusted multi-venue splitting, dark-first option), its zero-allocation hot-lane sibling HftSor, and the full-checklist AdaptiveSor (expected-cost routing over displayed + hidden liquidity, fees/rebates, latency, fill probability and a reliability veto, with contingent dark probes) learning from VenueScorecard (streaming per-venue fill rate, measured latency, realized dark fills), TwapScheduler / VwapScheduler (schedule design with anti-gaming jitter and exact largest-remainder allocation), PovTracker (streaming percentage-of-volume participation), ImplementationShortfallScheduler (Almgren-Chriss-optimal slicing), WmrFixingScheduler (benchmark-window TWAP replication), BenchmarkExecutor (the DYNAMIC benchmark algo: one stateful executor tracking VWAP / TWAP / Arrival / Implementation Shortfall / Closing / Opening / Participation, re-deciding each interval from live spread, depth, volatility, volume curve, alpha and liquidity — cross-asset), LiquiditySeekingAlgo (the opportunistic archetype: burst when the spread is under its time-of-day forecast in a calm regime, guaranteed by a completion floor over the final stretch), PortfolioExecutor (multi-symbol portfolio-level scheduling over per-symbol BenchmarkExecutor children: leg-balance band for two-sided transitions, per-interval notional budget allocated risk-weighted — overlays only ever damp a child's own due, so per-symbol benchmark integrity holds), IcebergOrder (display/reload state machine), DarkPoolSimulator (midpoint cross with minimum-execution-quantity), MidPegTracker (peg repricing with thresholds) and VenueBenchmark (fill rate, effective spread, markout per venue).
Zero-dependency FIX 4.4 engine.
Market data transport, two lanes:
Market microstructure analytics: MarketImpactModel (square-root law + Almgren-Chriss temporary/permanent decomposition), AlmgrenChriss (closed-form optimal execution trajectories on the cost/risk frontier), QueueModel (fill probability from queue position and latency advantage), TransactionCostAnalyzer (implementation shortfall, slippage vs VWAP, effective spread per fill), TickSizeSchedule (banded price grids) and Auction (call uncross).
Limit order book modeling, in two deliberate lanes: OrderBook is the research-grade model (price-time-priority matching with cancels, partial fills, queue-position queries and order-to-trade counters — readable TreeMap/object internals); HftOrderBook is the venue-grade core (dense integer-tick price ladder with occupancy bitmaps, pooled intrusive order nodes, primitive open-addressing id map, zero allocation — ~204 ns/op, 10M+ fills/sec measured by HftBookBenchmark).
Benchmark and regulatory metrics: FixAnalyzer (WM/Reuters-style fix calculation and "banging the close" screening), BestExecutionAnalyzer (MiFID II-style slippage, latency-to-fill and per-venue reporting) and MarketQualityMetrics (quoted/effective/realized spread, price impact, order-to-trade ratio).
Risk: measurement, decomposition, credit/limits, and model validation.
SBE-style binary wire codecs and channel adapters — the professional-grade alternative to the text edges (JSON WebSocket in, FIX tag-value out): TradeFlyweight, OrderFlyweight and QuoteFlyweight encode/decode at fixed buffer offsets with zero allocation, zero parsing and zero copying; BinaryMarketDataClient feeds the HftMarketDataBus from a binary stream and BinaryOrderPublisher/BinaryOrderReceiver carry gateway orders over a binary channel.
Order entry, two lanes (mirroring marketdata):
  • Uses of Side in com.quantfinlib.backtest

    Methods in com.quantfinlib.backtest that return Side
    Modifier and Type
    Method
    Description
    ParentOrder.side()
    Returns the value of the side record component.
    Methods in com.quantfinlib.backtest with parameters of type Side
    Modifier and Type
    Method
    Description
    ExecutionModel.execute(Side side, long requestedQty, BarSeries series, int index)
    Executes up to requestedQty on this bar.
    IcebergExecution.execute(Side side, long requestedQty, BarSeries series, int index)
     
    InstantExecution.execute(Side side, long requestedQty, BarSeries series, int index)
     
    LastLookExecution.execute(Side side, long requestedQty, BarSeries series, int index)
     
    SorExecution.execute(Side side, long requestedQty, BarSeries series, int index)
     
    default void
    ExecutionModel.onParentOrder(Side side, long totalQuantity, int signalIndex)
    Notification that a new parent order has been created (entry or exit).
    void
    IcebergExecution.onParentOrder(Side side, long totalQuantity, int signalIndex)
     
    void
    LastLookExecution.onParentOrder(Side side, long totalQuantity, int signalIndex)
     
    ExecutionAlgoBacktester.run(BarSeries series, Side side, long parentQty, BenchmarkExecutor.Benchmark benchmark)
    ExecutionAlgoBacktester.run(BarSeries series, Side side, long parentQty, BenchmarkExecutor.Benchmark benchmark, double povRate)
    Works parentQty through the session under benchmark and grades it.
    Constructors in com.quantfinlib.backtest with parameters of type Side
    Modifier
    Constructor
    Description
     
    ParentOrder(Side side, int signalIndex, double arrivalPrice, String reason, List<Execution> fills, int[] fillBarIndices)
    Creates an instance of a ParentOrder record class.
  • Uses of Side in com.quantfinlib.backtest.tick

    Methods in com.quantfinlib.backtest.tick with parameters of type Side
    Modifier and Type
    Method
    Description
    long
    TickBacktester.submitLimit(int symbolId, Side side, double price, long quantity)
     
    long
    TickTradingContext.submitLimit(int symbolId, Side side, double price, long quantity)
    Places a passive limit order.
    long
    TickBacktester.submitMarket(int symbolId, Side side, long quantity)
     
    long
    TickTradingContext.submitMarket(int symbolId, Side side, long quantity)
    Immediate execution at the last trade price plus half the configured spread (aggressor pays the spread).
  • Uses of Side in com.quantfinlib.execution

    Methods in com.quantfinlib.execution that return Side
    Modifier and Type
    Method
    Description
    BenchmarkExecutor.side()
     
    VenueBenchmark.Sample.side()
    Returns the value of the side record component.
    Methods in com.quantfinlib.execution with parameters of type Side
    Modifier and Type
    Method
    Description
    BenchmarkExecutor.of(Side side, long parentQty, BenchmarkExecutor.Benchmark benchmark)
    Sensible defaults: alpha urgency 1 (a full-scale normalized alpha of ±1 doubles/halves the pace — smooth, never rail-pinned), child capped at 25% of displayed depth.
    BenchmarkExecutor.pov(Side side, long parentQty, double participationRate)
    POV convenience.
    long
    DarkPoolSimulator.restingQty(Side side)
    Total hidden resting quantity on a side (for simulation introspection only).
    AdaptiveSor.route(Side side, long quantity, List<VenueQuote> venues)
    Routes a marketable parent of quantity.
    long
    HftSor.route(Side side, long quantity, int limitTick, long[] outQty)
    Routes a marketable order across venues by best all-in price (quote ± fee), splitting at displayed size.
    SmartOrderRouter.route(Side side, long quantity, List<VenueQuote> venues, boolean preferDark)
     
    DarkPoolSimulator.submit(Side side, long quantity, long minExecutionQty)
    Submits an order: crosses immediately against resting contra interest at the current mid (time priority), then rests the remainder.
    Constructors in com.quantfinlib.execution with parameters of type Side
    Modifier
    Constructor
    Description
     
    BenchmarkExecutor(Side side, long parentQty, BenchmarkExecutor.Benchmark benchmark, double participationRate, double alphaUrgency, double maxDepthFraction)
     
     
    MidPegTracker(Side side, double offset, double limitPrice, double repriceThreshold)
     
     
    Sample(String venue, Side side, double price, long quantity, double midAtExec, double midAfterHorizon, long latencyToFillNanos, boolean filled)
    Creates an instance of a Sample record class.
  • Uses of Side in com.quantfinlib.fix

    Methods in com.quantfinlib.fix that return Side
    Modifier and Type
    Method
    Description
    ExecutionReport.side()
    Returns the value of the side record component.
    NewOrderSingle.side()
    Returns the value of the side record component.
    OrderCancelReplaceRequest.side()
    Returns the value of the side record component.
    OrderCancelRequest.side()
    Returns the value of the side record component.
    Methods in com.quantfinlib.fix with parameters of type Side
    Modifier and Type
    Method
    Description
    int
    FixOrderEncoder.encodeLimit(long msgSeqNum, long clOrdId, int symbolId, Side side, long quantity, long priceMantissa, int priceDecimals, long epochMillis)
    Encodes a limit NewOrderSingle into the reusable buffer.
    int
    FixOrderEncoder.encodeMarket(long msgSeqNum, long clOrdId, int symbolId, Side side, long quantity, long epochMillis)
    Market NewOrderSingle (40=1, no price tag).
    FixSession.sendNewOrderSingle(String clOrdId, String symbol, Side side, long quantity, double limitPrice, char timeInForce)
    Sends a NewOrderSingle.
    FixSession.sendOrderCancelReplace(String clOrdId, String origClOrdId, String symbol, Side side, long quantity, double limitPrice, char timeInForce)
    Sends an OrderCancelReplaceRequest (35=G); limitPrice = NaN = market.
    FixSession.sendOrderCancelRequest(String clOrdId, String origClOrdId, String symbol, Side side, long quantity)
    Sends an OrderCancelRequest (35=F) for a working order.
    Constructors in com.quantfinlib.fix with parameters of type Side
    Modifier
    Constructor
    Description
     
    ExecutionReport(String orderId, String execId, char execType, char ordStatus, String clOrdId, String symbol, Side side, double lastQty, double lastPrice, double cumQty, double leavesQty, double avgPrice)
    Creates an instance of a ExecutionReport record class.
     
    NewOrderSingle(String clOrdId, String symbol, Side side, long quantity, char ordType, double price, char timeInForce)
    Creates an instance of a NewOrderSingle record class.
     
    OrderCancelReplaceRequest(String clOrdId, String origClOrdId, String symbol, Side side, long quantity, char ordType, double price, char timeInForce)
    Creates an instance of a OrderCancelReplaceRequest record class.
     
    OrderCancelRequest(String clOrdId, String origClOrdId, String symbol, Side side, long quantity)
    Creates an instance of a OrderCancelRequest record class.
  • Uses of Side in com.quantfinlib.marketdata

    Methods in com.quantfinlib.marketdata with parameters of type Side
    Modifier and Type
    Method
    Description
    boolean
    L3BookBuilder.onAdd(long ref, Side side, long shares, int priceTick)
    Add order: appends to its level's FIFO.
    long
    L3BookBuilder.qtyAtTick(Side side, int priceTick)
    Resting quantity at an absolute tick (0 when off-band or empty).
    int
    L3BookBuilder.snapshot(Side side, int[] outTicks, long[] outQtys)
    Depth snapshot into caller arrays, best-first; returns levels written.
  • Uses of Side in com.quantfinlib.microstructure

    Methods in com.quantfinlib.microstructure that return Side
    Modifier and Type
    Method
    Description
    Execution.side()
    Returns the value of the side record component.
    Constructors in com.quantfinlib.microstructure with parameters of type Side
    Modifier
    Constructor
    Description
     
    Execution(String symbol, Side side, double price, long quantity, long timestampNanos, String venue)
    Creates an instance of a Execution record class.
  • Uses of Side in com.quantfinlib.orderbook

    Subclasses with type arguments of type Side in com.quantfinlib.orderbook
    Modifier and Type
    Class
    Description
    enum 
    Order side.
    Methods in com.quantfinlib.orderbook that return Side
    Modifier and Type
    Method
    Description
    Side.opposite()
     
    LimitOrder.side()
     
    static Side
    Side.valueOf(String name)
    Returns the enum constant of this class with the specified name.
    static Side[]
    Side.values()
    Returns an array containing the constants of this enum class, in the order they are declared.
    Methods in com.quantfinlib.orderbook with parameters of type Side
    Modifier and Type
    Method
    Description
    long
    OrderBook.depth(Side side, int maxLevels)
    Total resting quantity on a side across its best maxLevels.
    static long
    BookAnalytics.depthWithinBps(OrderBook book, Side side, double bps)
    Resting quantity on a side priced within bps of the mid.
    List<double[]>
    OrderBook.levels(Side side, int maxLevels)
    Price/quantity pairs for the given side's best maxLevels (side = the resting liquidity side: BUY returns bids).
    long
    HftOrderBook.qtyAtTick(Side side, int priceTick)
    Resting quantity at an absolute tick (0 when off-band or empty).
    int
    HftOrderBook.snapshot(Side side, int[] outTicks, long[] outQtys)
    Depth snapshot into caller-provided arrays (absolute ticks + level quantities, best-first): zero allocation.
    long
    HftOrderBook.submitFok(Side side, int priceTick, long quantity, long timestampNanos)
    Fill-or-kill: executes the full quantity within the limit price or does nothing at all.
    long
    HftOrderBook.submitIoc(Side side, int priceTick, long quantity, long timestampNanos)
    Immediate-or-cancel: a price-limited taker — matches while it crosses, and the remainder expires instead of resting.
    long
    HftOrderBook.submitLimit(Side side, int priceTick, long quantity, long timestampNanos)
    Limit order: matches against the opposite side while it crosses, rests any remainder at priceTick.
    long
    OrderBook.submitLimit(Side side, double price, long quantity, long timestampNanos)
    Submits a limit order: matches any crossing liquidity, then rests the remainder.
    long
    HftOrderBook.submitMarket(Side side, long quantity, long timestampNanos)
    Market order: matches against the whole opposite book, never rests.
    long
    OrderBook.submitMarket(Side side, long quantity, long timestampNanos)
    Submits a market order; any unfilled remainder is discarded.
    long
    HftOrderBook.submitPostOnly(Side side, int priceTick, long quantity, long timestampNanos)
    Post-only (add-liquidity-only) limit order: rests at priceTick, or is rejected with HftOrderBook.REJECT_WOULD_CROSS when it would trade on arrival — the maker-fee-preserving order type.
    BookAnalytics.sweep(OrderBook book, Side takerSide, long quantity)
    Simulates (without mutating the book) sweeping quantity with a marketable order on takerSide: returns achievable fill, VWAP fill price, and impact versus the pre-sweep mid.
  • Uses of Side in com.quantfinlib.regulatory

    Methods in com.quantfinlib.regulatory that return Side
    Modifier and Type
    Method
    Description
    BestExecutionAnalyzer.OrderOutcome.side()
    Returns the value of the side record component.
    Methods in com.quantfinlib.regulatory with parameters of type Side
    Modifier and Type
    Method
    Description
    static double
    MarketQualityMetrics.effectiveSpreadBps(Side takerSide, double price, double midAtExecution)
    Effective spread: 2 * sign * (price - mid) / mid — what the taker actually paid.
    static double
    MarketQualityMetrics.priceImpactBps(Side takerSide, double midAtExecution, double midAfterHorizon)
    Price impact: how far the mid moved in the taker's direction after the trade (2 * sign * (midAfter - midAtExec) / midAtExec); effective spread ≈ realized spread + price impact.
    static double
    MarketQualityMetrics.realizedSpreadBps(Side takerSide, double price, double midAfterHorizon)
    Realized spread: effective spread measured against the mid some horizon after the trade — the part of the spread the liquidity provider kept after adverse selection.
    Constructors in com.quantfinlib.regulatory with parameters of type Side
    Modifier
    Constructor
    Description
     
    OrderOutcome(String orderId, String venue, Side side, long quantity, double arrivalMid, double executionPrice, long latencyToFillNanos, boolean filled)
    Creates an instance of a OrderOutcome record class.
  • Uses of Side in com.quantfinlib.risk

    Methods in com.quantfinlib.risk that return Side
    Modifier and Type
    Method
    Description
    PreTradeLimitChecker.OrderRequest.side()
    Returns the value of the side record component.
    Constructors in com.quantfinlib.risk with parameters of type Side
    Modifier
    Constructor
    Description
     
    OrderRequest(String symbol, Side side, long quantity, double price, String counterparty)
    Creates an instance of a OrderRequest record class.
  • Uses of Side in com.quantfinlib.sbe

    Methods in com.quantfinlib.sbe that return Side
    Modifier and Type
    Method
    Description
    OrderFlyweight.side()
     
    Methods in com.quantfinlib.sbe with parameters of type Side
    Modifier and Type
    Method
    Description
    OrderFlyweight.encode(long orderId, int symbolId, Side side, long quantity, double price, long timestampNanos)
    Encodes a full order message at the wrap position (writes the type header).
    void
    BinaryOrderPublisher.onOrder(long orderId, int symbolId, Side side, long quantity, double price, long timestampNanos)
     
  • Uses of Side in com.quantfinlib.trading

    Methods in com.quantfinlib.trading with parameters of type Side
    Modifier and Type
    Method
    Description
    int
    HftRiskGate.check(int symbolId, Side side, long quantity, double price)
    Validates one order.
    void
    HftRiskGate.onFill(int symbolId, Side side, long quantity)
    Applies a fill to the position book — callable from the venue-ack thread (atomic add: concurrent fill sources cannot lose updates).
    void
    OrderGateway.ExecutionListener.onFill(long orderId, String symbol, Side side, double price, long quantity, long timestampNanos)
     
    void
    OrderListener.onOrder(long orderId, int symbolId, Side side, long quantity, double price, long timestampNanos)
     
    boolean
    OrderRingBuffer.publish(long orderId, int symbolId, Side side, long quantity, double price, long timestampNanos)
    Producer side (trading thread).
    long
    HftOrderGateway.submit(int symbolId, Side side, long quantity, double price, long timestampNanos)
    Risk-checks and submits one order.
    long
    OrderGateway.submitLimit(String symbol, Side side, long quantity, double price)
    Submits a limit order; returns the order id (status may be REJECTED).
    long
    PaperTradingGateway.submitLimit(String symbol, Side side, long quantity, double price)
     
    long
    OrderGateway.submitMarket(String symbol, Side side, long quantity)
    Submits a market order for immediate execution at the touch.
    long
    PaperTradingGateway.submitMarket(String symbol, Side side, long quantity)