Class Order

java.lang.Object
org.drip.oms.transaction.Order
Direct Known Subclasses:
LimitOrder, MarketOrder, StopOrder

public abstract class Order
extends java.lang.Object
Order holds the Details of an Order. The References are:

  • Berkowitz, S. A., D. E. Logue, and E. A. J. Noser (1988): The Total Cost of Transactions on the NYSE Journal of Finance 43 (1) 97-112
  • Cont, R., and A. Kukanov (2017): Optimal Order Placement in Limit Order Markets Quantitative Finance 17 (1) 21-39
  • Vassilis, P. (2005a): A Realistic Model of Market Liquidity and Depth Journal of Futures Markets 25 (5) 443-464
  • 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


Author:
Lakshmi Krishnamurthy
  • Constructor Summary

    Constructors
    Constructor Description
    Order​(OrderIssuer issuer, java.lang.String ticker, java.lang.String id, int type, java.util.Date creationTime, Side side, double size, TimeInForce timeInForce, OrderFillWholeSettings fillWholeSettings, DisplaySettings displaySettings)
    Order Constructor
  • Method Summary

    Modifier and Type Method Description
    boolean allOrNone()
    Retrieve the All-or-None Flag
    boolean amendSize​(double orderSize)
    Amend the Order Size
    java.util.Date completionTime()
    Retrieve the Order Completion Time
    java.util.Date creationTime()
    Retrieve the Order Creation Time
    double displayAmount()
    Retrieve the Order Display Amount
    DisplaySettings displaySettings()
    Retrieve the Order Display Settings
    boolean fillOrKill()
    Retrieve the Fill-or-Kill Flag
    OrderFillWholeSettings fillWholeSettings()
    Retrieve the Fill-Whole Settings
    Order fulfill​(OrderFulfillment orderFulfillment)
    Fill an Order Partially/Fully
    abstract Order generateChildOrder​(double filledSize)
    Generate a Child Order of the same Type
    java.lang.String id()
    Retrieve the Order ID
    abstract boolean isConditional()
    Indicate if the Order is Conditional
    boolean isOutstanding()
    Indicate if the Order is Outstanding
    OrderIssuer issuer()
    Retrieve the Order Issuer
    boolean setComplete​(java.util.Date completionTime)
    Set the Order Completion Time
    boolean setState​(int orderState)
    Set the Order State
    Side side()
    Retrieve the Order Side
    double size()
    Retrieve the Order Size
    int state()
    Retrieve the Order State
    java.lang.String ticker()
    Retrieve the Order Security Identifier/Ticker
    TimeInForce timeInForce()
    Retrieve the Time-in-Force Settings
    int type()
    Retrieve the Order Type
    java.util.Date updateTime()
    Retrieve the Order Update Time

    Methods inherited from class java.lang.Object

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

    • Order

      public Order​(OrderIssuer issuer, java.lang.String ticker, java.lang.String id, int type, java.util.Date creationTime, Side side, double size, TimeInForce timeInForce, OrderFillWholeSettings fillWholeSettings, DisplaySettings displaySettings) throws java.lang.Exception
      Order Constructor
      Parameters:
      issuer - Order Issuer
      ticker - Security Identifier/Ticker
      id - Order ID
      type - Order Type
      creationTime - Creation Time
      side - Order Side
      size - Order Size
      timeInForce - Time-in-Force Settings
      fillWholeSettings - Order Fill-Whole Settings
      displaySettings - Order Display Settings
      Throws:
      java.lang.Exception - Thrown if the Inputs are Invalid
  • Method Details

    • ticker

      public java.lang.String ticker()
      Retrieve the Order Security Identifier/Ticker
      Returns:
      The Order Security Identifier/Ticker
    • id

      public java.lang.String id()
      Retrieve the Order ID
      Returns:
      The Order ID
    • issuer

      public OrderIssuer issuer()
      Retrieve the Order Issuer
      Returns:
      The Order Issuer
    • type

      public int type()
      Retrieve the Order Type
      Returns:
      The Order Type
    • state

      public int state()
      Retrieve the Order State
      Returns:
      The Order State
    • creationTime

      public java.util.Date creationTime()
      Retrieve the Order Creation Time
      Returns:
      The Order Creation Time
    • updateTime

      public java.util.Date updateTime()
      Retrieve the Order Update Time
      Returns:
      The Order Update Time
    • completionTime

      public java.util.Date completionTime()
      Retrieve the Order Completion Time
      Returns:
      The Order Completion Time
    • timeInForce

      public TimeInForce timeInForce()
      Retrieve the Time-in-Force Settings
      Returns:
      The Time-in-Force Settings
    • fillWholeSettings

      public OrderFillWholeSettings fillWholeSettings()
      Retrieve the Fill-Whole Settings
      Returns:
      The Fill-Whole Settings
    • side

      public Side side()
      Retrieve the Order Side
      Returns:
      The Order Side
    • size

      public double size()
      Retrieve the Order Size
      Returns:
      The Order Size
    • displaySettings

      public DisplaySettings displaySettings()
      Retrieve the Order Display Settings
      Returns:
      The Order Display Settings
    • isConditional

      public abstract boolean isConditional()
      Indicate if the Order is Conditional
      Returns:
      TRUE - Order is Conditional
    • generateChildOrder

      public abstract Order generateChildOrder​(double filledSize)
      Generate a Child Order of the same Type
      Parameters:
      filledSize - Filled Size
      Returns:
      Child Order of the same Type
    • fillOrKill

      public boolean fillOrKill()
      Retrieve the Fill-or-Kill Flag
      Returns:
      The Fill-or-Kill Flag
    • allOrNone

      public boolean allOrNone()
      Retrieve the All-or-None Flag
      Returns:
      The All-or-None Flag
    • setState

      public boolean setState​(int orderState)
      Set the Order State
      Parameters:
      orderState - Order State
      Returns:
      TRUE - The Order State successfully set
    • amendSize

      public boolean amendSize​(double orderSize)
      Amend the Order Size
      Parameters:
      orderSize - Order Size
      Returns:
      TRUE - The Order Size successfully set
    • fulfill

      public Order fulfill​(OrderFulfillment orderFulfillment)
      Fill an Order Partially/Fully
      Parameters:
      orderFulfillment - Order Fulfillment
      Returns:
      Child Order, if any
    • isOutstanding

      public boolean isOutstanding()
      Indicate if the Order is Outstanding
      Returns:
      TRUE - Order is Outstanding
    • setComplete

      public boolean setComplete​(java.util.Date completionTime)
      Set the Order Completion Time
      Parameters:
      completionTime - The Order Completion Time
      Returns:
      TRUE - Order is Set to Complete
    • displayAmount

      public double displayAmount()
      Retrieve the Order Display Amount
      Returns:
      Order Display Amount