From 8232759f8c251b416f0433b8406d714476cda6b3 Mon Sep 17 00:00:00 2001 From: 7u83 <7u83@mail.ru> Date: Sat, 8 Dec 2018 18:34:06 +0100 Subject: [PATCH] Removed old code --- src/opensesim/world/Order.java | 19 +++++-------------- 1 file changed, 5 insertions(+), 14 deletions(-) diff --git a/src/opensesim/world/Order.java b/src/opensesim/world/Order.java index ab6c5cc..e4cbabe 100644 --- a/src/opensesim/world/Order.java +++ b/src/opensesim/world/Order.java @@ -69,18 +69,18 @@ public class Order implements Comparable { } - public enum OrderStatus { + public static enum Status { OPEN, PARTIALLY_EXECUTED, CLOSED, CANCELED } /** * Definition of order types */ - public enum Type { + public static enum Type { BUYLIMIT, SELLLIMIT, STOPLOSS, STOPBUY, BUY, SELL } - protected OrderStatus status; + protected Status status; protected Type type; protected double limit; protected double volume; @@ -103,7 +103,7 @@ public class Order implements Comparable { this.volume = volume; this.initial_volume = this.volume; this.created = 0; - this.status = OrderStatus.OPEN; + this.status = Status.OPEN; this.cost = 0; // id = Order.idGenerator.getNext(); this.world = world; @@ -151,7 +151,7 @@ public class Order implements Comparable { return account; } - public OrderStatus getOrderStatus() { + public Status getOrderStatus() { return status; } @@ -159,14 +159,5 @@ public class Order implements Comparable { return created; } - /** - * Get the stock symbol that this order belongs to - * - * @return Stock symbol - */ - public String getStockSymbol() { - // return stock.getSymbol(); - return null; - } }