Class PriceBook

java.lang.Object
org.drip.oms.depth.PriceBook

public class PriceBook
extends java.lang.Object
PriceBook maintains the Ordered Price Book Entry for a Ticker/Venue. The References are:

  • Chen, J. (2021): Time in Force: Definition, Types, and Examples https://www.investopedia.com/terms/t/timeinforce.asp
  • Cont, R., and A. Kukanov (2017): Optimal Order Placement in Limit Order Markets Quantitative Finance 17 (1) 21-39
  • Vassilis, P. (2005b): Slow and Fast Markets Journal of Economics and Business 57 (6) 576-593
  • Weiss, D. (2006): After the Trade is Made: Processing Securities Transactions Portfolio Publishing London UK
  • Wikipedia (2023): Central Limit Order Book https://en.wikipedia.org/wiki/Central_limit_order_book


Author:
Lakshmi Krishnamurthy
  • Constructor Summary

    Constructors
    Constructor Description
    PriceBook()
    PriceBook Constructor
  • Method Summary

    Modifier and Type Method Description
    java.util.TreeMap<java.lang.Double,​OrderBlock> aggregatedPostedBlockMap()
    Retrieve the Aggregated Posted Block Price Map
    boolean aggregatePostedBlock​(OrderBlock postedBlock)
    Aggregate a Posted Block to the Price Book
    boolean disaggregateSweptBlock​(OrderBlock sweptBlock, boolean allowPartialSweep)
    Disaggregate a Swept Block to the Price Book
    OrderBlock topOfTheBook​(boolean bid)
    Retrieve the Top-of-the-Book

    Methods inherited from class java.lang.Object

    equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • PriceBook

      public PriceBook()
      PriceBook Constructor
  • Method Details

    • aggregatedPostedBlockMap

      public java.util.TreeMap<java.lang.Double,​OrderBlock> aggregatedPostedBlockMap()
      Retrieve the Aggregated Posted Block Price Map
      Returns:
      The Aggregated Posted Block Price Map
    • aggregatePostedBlock

      public boolean aggregatePostedBlock​(OrderBlock postedBlock)
      Aggregate a Posted Block to the Price Book
      Parameters:
      postedBlock - Posted Block
      Returns:
      TRUE - The Posted Block successfully aggregated to the Price Book
    • disaggregateSweptBlock

      public boolean disaggregateSweptBlock​(OrderBlock sweptBlock, boolean allowPartialSweep)
      Disaggregate a Swept Block to the Price Book
      Parameters:
      sweptBlock - Swept Block
      allowPartialSweep - TRUE - Partial Sweep is allowed
      Returns:
      TRUE - The Swept Block successfully disaggregated to the Price Book
    • topOfTheBook

      public OrderBlock topOfTheBook​(boolean bid)
      Retrieve the Top-of-the-Book
      Parameters:
      bid - TRUE - Top-of-the-Bid-Book
      Returns:
      The Top-of-the-Book