public class Strategy extends AbstractRunningStrategy
RunningStrategy implementation for Java strategies to extend.| Constructor and Description |
|---|
Strategy() |
| Modifier and Type | Method and Description |
|---|---|
protected void |
debug(String inMessage)
Emits the given debug message to the strategy log output.
|
protected void |
error(String inMessage)
Emits the given error message to the strategy log output.
|
protected void |
info(String inMessage)
Emits the given info message to the strategy log output.
|
protected void |
notifyHigh(String inSubject,
String inBody)
Creates and issues a
Notification at high priority. |
protected void |
notifyLow(String inSubject,
String inBody)
Creates and issues a
Notification at low priority. |
protected void |
notifyMedium(String inSubject,
String inBody)
Creates and issues a
Notification at medium priority. |
void |
onAsk(AskEvent inAsk)
Indicates an
AskEvent has been received. |
void |
onBid(BidEvent inBid)
Indicates a
BidEvent has been received. |
void |
onCallback(Object inData)
Indicates a scheduled callback has been executed.
|
void |
onCancelReject(OrderCancelReject inCancel)
Indicates an
OrderCancelReject has been received. |
void |
onDividend(DividendEvent inStatistics)
Indicates a
DividendEvent has been received. |
void |
onExecutionReport(ExecutionReport inExecutionReport)
Indicates an
ExecutionReport has been received. |
void |
onMarketstat(MarketstatEvent inStatistics)
Indicates a
MarketstatEvent has been received. |
void |
onOther(Object inEvent)
Indicates an object has been sent that does not fit any of the other callbacks.
|
void |
onReceiveBrokerStatus(BrokerStatus inStatus)
Indicates a
BrokerStatus has been received. |
void |
onStart()
Called when a strategy is started.
|
void |
onStop()
Called when a strategy is about to be stopped.
|
void |
onTrade(TradeEvent inTrade)
Indicates a
TradeEvent has been received. |
protected boolean |
send(Object inData)
Sends an order to order subscribers.
|
protected void |
warn(String inMessage)
Emits the given warn message to the strategy log output.
|
cancelAllDataRequests, cancelAllOrders, cancelDataFlow, cancelDataRequest, cancelOrder, cancelReplace, createDataFlow, getAllCurrencyPositionsAsOf, getAllFuturePositionsAsOf, getAllOptionPositionsAsOf, getAllPositionsAsOf, getBrokers, getCurrencyPositionAsOf, getExecutionReports, getFuturePositionAsOf, getOpenOrderIDs, getOpenOrders, getOptionPositionAsOf, getOptionPositionsAsOf, getOptionRoots, getOrderStatus, getParameter, getPositionAsOf, getProperty, getReportHistoryOriginDate, getSubmittedOrderIDs, getUnderlying, getURN, getUserData, initializeReportHistoryManager, receiveBrokerStatus, requestCallbackAfter, requestCallbackAt, requestCallbackEvery, requestCEPData, requestMarketData, requestMarketData, requestProcessedMarketData, requestProcessedMarketData, sendEvent, sendEventToCEP, sendMessage, sendNotification, setProperty, setUserData, suggestTrade, toStringpublic void onAsk(AskEvent inAsk)
RunningStrategyAskEvent has been received.inAsk - an AskEvent valuepublic void onBid(BidEvent inBid)
RunningStrategyBidEvent has been received.inBid - a BidEvent valuepublic void onMarketstat(MarketstatEvent inStatistics)
RunningStrategyMarketstatEvent has been received.inStatistics - a MarketstatEvent valuepublic void onDividend(DividendEvent inStatistics)
RunningStrategyDividendEvent has been received.inStatistics - a DividendEvent valuepublic void onCallback(Object inData)
RunningStrategyinData - an Object value passed to the request for callback methodpublic void onExecutionReport(ExecutionReport inExecutionReport)
RunningStrategyExecutionReport has been received.inExecutionReport - an ExecutionReport valuepublic void onCancelReject(OrderCancelReject inCancel)
RunningStrategyOrderCancelReject has been received.inCancel - an OrderCancelReject valuepublic void onReceiveBrokerStatus(BrokerStatus inStatus)
RunningStrategyBrokerStatus has been received.inStatus - a BrokerStatus valuepublic void onOther(Object inEvent)
RunningStrategyinEvent - an Object valuepublic void onTrade(TradeEvent inTrade)
RunningStrategyTradeEvent has been received.inTrade - a TradeEvent valuepublic void onStart()
RunningStrategypublic void onStop()
RunningStrategyprotected final void notifyLow(String inSubject, String inBody)
Notification at low priority.inSubject - a String valueinBody - a String valueprotected final void notifyMedium(String inSubject, String inBody)
Notification at medium priority.inSubject - a String valueinBody - a String valueprotected final void notifyHigh(String inSubject, String inBody)
Notification at high priority.inSubject - a String valueinBody - a String valueprotected final void debug(String inMessage)
debug in class AbstractRunningStrategyinMessage - a String valueprotected final void info(String inMessage)
info in class AbstractRunningStrategyinMessage - a String valueprotected final void warn(String inMessage)
warn in class AbstractRunningStrategyinMessage - a String valueprotected final void error(String inMessage)
error in class AbstractRunningStrategyinMessage - a String valueprotected final boolean send(Object inData)
send in class AbstractRunningStrategyinData - an Object valueboolean value indicating whether the object was successfully transmitted or notCopyright © 2020. All rights reserved.