Removed old code

This commit is contained in:
7u83 2018-12-08 18:34:06 +01:00
parent f9fbc63763
commit 8232759f8c
1 changed files with 5 additions and 14 deletions

View File

@ -69,18 +69,18 @@ public class Order implements Comparable<Order> {
} }
public enum OrderStatus { public static enum Status {
OPEN, PARTIALLY_EXECUTED, CLOSED, CANCELED OPEN, PARTIALLY_EXECUTED, CLOSED, CANCELED
} }
/** /**
* Definition of order types * Definition of order types
*/ */
public enum Type { public static enum Type {
BUYLIMIT, SELLLIMIT, STOPLOSS, STOPBUY, BUY, SELL BUYLIMIT, SELLLIMIT, STOPLOSS, STOPBUY, BUY, SELL
} }
protected OrderStatus status; protected Status status;
protected Type type; protected Type type;
protected double limit; protected double limit;
protected double volume; protected double volume;
@ -103,7 +103,7 @@ public class Order implements Comparable<Order> {
this.volume = volume; this.volume = volume;
this.initial_volume = this.volume; this.initial_volume = this.volume;
this.created = 0; this.created = 0;
this.status = OrderStatus.OPEN; this.status = Status.OPEN;
this.cost = 0; this.cost = 0;
// id = Order.idGenerator.getNext(); // id = Order.idGenerator.getNext();
this.world = world; this.world = world;
@ -151,7 +151,7 @@ public class Order implements Comparable<Order> {
return account; return account;
} }
public OrderStatus getOrderStatus() { public Status getOrderStatus() {
return status; return status;
} }
@ -159,14 +159,5 @@ public class Order implements Comparable<Order> {
return created; return created;
} }
/**
* Get the stock symbol that this order belongs to
*
* @return Stock symbol
*/
public String getStockSymbol() {
// return stock.getSymbol();
return null;
}
} }