@Override public void tickEFP( final int tickerId, final int tickType, final double basisPoints, final String formattedBasisPoints, final double impliedFuture, final int holdDays, final String futureExpiry, final double dividendImpact, final double dividendsToExpiry) { final TickEFP o = new TickEFP( tickerId, tickType, basisPoints, formattedBasisPoints, impliedFuture, holdDays, futureExpiry, dividendImpact, dividendsToExpiry); ServiceLocator.commonInstance().getRuleService().sendEvent(StrategyImpl.BASE, o); logger.trace( EWrapperMsgGenerator.tickEFP( tickerId, tickType, basisPoints, formattedBasisPoints, impliedFuture, holdDays, futureExpiry, dividendImpact, dividendsToExpiry)); }
@Override public void tickOptionComputation( final int tickerId, final int field, final double impliedVol, final double delta, final double optPrice, final double pvDividend, final double gamma, final double vega, final double theta, final double undPrice) { final TickOptionComputation o = new TickOptionComputation( tickerId, field, impliedVol, delta, optPrice, pvDividend, gamma, vega, theta, undPrice); ServiceLocator.commonInstance().getRuleService().sendEvent(StrategyImpl.BASE, o); logger.trace( EWrapperMsgGenerator.tickOptionComputation( tickerId, field, impliedVol, delta, optPrice, pvDividend, gamma, vega, theta, undPrice)); }
@Override public void tickPrice( final int tickerId, final int field, final double price, final int canAutoExecute) { final TickPrice o = new TickPrice(tickerId, field, price, canAutoExecute); ServiceLocator.commonInstance().getRuleService().sendEvent(StrategyImpl.BASE, o); logger.trace(EWrapperMsgGenerator.tickPrice(tickerId, field, price, canAutoExecute)); }
@Override public void openOrder( final int orderId, final Contract contract, final Order order, final OrderState orderState) { final OpenOrder o = new OpenOrder(orderId, contract, order, orderState); ServiceLocator.commonInstance().getRuleService().sendEvent(StrategyImpl.BASE, o); logger.debug(EWrapperMsgGenerator.openOrder(orderId, contract, order, orderState)); }
@Override public void updateNewsBulletin( final int msgId, final int msgType, final String message, final String origExchange) { final UpdateNewsBulletin o = new UpdateNewsBulletin(msgId, msgType, message, origExchange); ServiceLocator.commonInstance().getRuleService().sendEvent(StrategyImpl.BASE, o); logger.debug(EWrapperMsgGenerator.updateNewsBulletin(msgId, msgType, message, origExchange)); }
@Override public void updateAccountValue( final String key, final String value, final String currency, final String accountName) { final UpdateAccountValue o = new UpdateAccountValue(key, value, currency, accountName); ServiceLocator.commonInstance().getRuleService().sendEvent(StrategyImpl.BASE, o); logger.debug(EWrapperMsgGenerator.updateAccountValue(key, value, currency, accountName)); }
@Override public void updatePortfolio( final Contract contract, final int position, final double marketPrice, final double marketValue, final double averageCost, final double unrealizedPNL, final double realizedPNL, final String accountName) { final UpdatePortfolio o = new UpdatePortfolio( contract, position, marketPrice, marketValue, averageCost, unrealizedPNL, realizedPNL, accountName); ServiceLocator.commonInstance().getRuleService().sendEvent(StrategyImpl.BASE, o); logger.debug( EWrapperMsgGenerator.updatePortfolio( contract, position, marketPrice, marketValue, averageCost, unrealizedPNL, realizedPNL, accountName)); }
@Override public void updateMktDepth( final int tickerId, final int position, final int operation, final int side, final double price, final int size) { final UpdateMktDepth o = new UpdateMktDepth(tickerId, position, operation, side, price, size); ServiceLocator.commonInstance().getRuleService().sendEvent(StrategyImpl.BASE, o); logger.debug( EWrapperMsgGenerator.updateMktDepth(tickerId, position, operation, side, price, size)); }
@Override public void realtimeBar( final int reqId, final long time, final double open, final double high, final double low, final double close, final long volume, final double wap, final int count) { final RealtimeBar o = new RealtimeBar(reqId, time, open, high, low, close, volume, wap, count); ServiceLocator.commonInstance().getRuleService().sendEvent(StrategyImpl.BASE, o); logger.debug( EWrapperMsgGenerator.realtimeBar(reqId, time, open, high, low, close, volume, wap, count)); }
@Override public void scannerData( final int reqId, final int rank, final ContractDetails contractDetails, final String distance, final String benchmark, final String projection, final String legsStr) { final ScannerData o = new ScannerData(reqId, rank, contractDetails, distance, benchmark, projection, legsStr); ServiceLocator.commonInstance().getRuleService().sendEvent(StrategyImpl.BASE, o); logger.debug( EWrapperMsgGenerator.scannerData( reqId, rank, contractDetails, distance, benchmark, projection, legsStr)); }
@Override public void historicalData( final int reqId, final String date, final double open, final double high, final double low, final double close, final int volume, final int count, final double wap, final boolean hasGaps) { final HistoricalData o = new HistoricalData(reqId, date, open, high, low, close, volume, count, wap, hasGaps); ServiceLocator.commonInstance().getRuleService().sendEvent(StrategyImpl.BASE, o); logger.debug( EWrapperMsgGenerator.historicalData( reqId, date, open, high, low, close, volume, count, wap, hasGaps)); }
@Override public void orderStatus( final int orderId, final String status, final int filled, final int remaining, final double avgFillPrice, final int permId, final int parentId, final double lastFillPrice, final int clientId, final String whyHeld) { final OrderStatus o = new OrderStatus( orderId, status, filled, remaining, avgFillPrice, permId, parentId, lastFillPrice, clientId, whyHeld); ServiceLocator.commonInstance().getRuleService().sendEvent(StrategyImpl.BASE, o); logger.debug( EWrapperMsgGenerator.orderStatus( orderId, status, filled, remaining, avgFillPrice, permId, parentId, lastFillPrice, clientId, whyHeld)); }
@Override public void scannerParameters(final String xml) { final ScannerParameters o = new ScannerParameters(xml); ServiceLocator.commonInstance().getRuleService().sendEvent(StrategyImpl.BASE, o); logger.debug(EWrapperMsgGenerator.scannerParameters(xml)); }
@Override public void managedAccounts(final String accountsList) { final ManagedAccounts o = new ManagedAccounts(accountsList); ServiceLocator.commonInstance().getRuleService().sendEvent(StrategyImpl.BASE, o); logger.debug(EWrapperMsgGenerator.managedAccounts(accountsList)); }
@Override public void updateAccountTime(final String timeStamp) { final UpdateAccountTime o = new UpdateAccountTime(timeStamp); ServiceLocator.commonInstance().getRuleService().sendEvent(StrategyImpl.BASE, o); logger.debug(EWrapperMsgGenerator.updateAccountTime(timeStamp)); }
@Override public void tickString(final int tickerId, final int tickType, final String value) { final TickString o = new TickString(tickerId, tickType, value); ServiceLocator.commonInstance().getRuleService().sendEvent(StrategyImpl.BASE, o); logger.trace(EWrapperMsgGenerator.tickString(tickerId, tickType, value)); }
@Override public void tickSnapshotEnd(final int reqId) { final TickSnapshotEnd o = new TickSnapshotEnd(reqId); ServiceLocator.commonInstance().getRuleService().sendEvent(StrategyImpl.BASE, o); logger.trace(EWrapperMsgGenerator.tickSnapshotEnd(reqId)); }
@Override public void tickSize(final int tickerId, final int field, final int size) { final TickSize o = new TickSize(tickerId, field, size); ServiceLocator.commonInstance().getRuleService().sendEvent(StrategyImpl.BASE, o); logger.trace(EWrapperMsgGenerator.tickSize(tickerId, field, size)); }
@Override public void accountDownloadEnd(final String accountName) { final AccountDownloadEnd o = new AccountDownloadEnd(accountName); ServiceLocator.commonInstance().getRuleService().sendEvent(StrategyImpl.BASE, o); logger.debug(EWrapperMsgGenerator.accountDownloadEnd(accountName)); }
@Override public void scannerDataEnd(final int reqId) { final ScannerDataEnd o = new ScannerDataEnd(reqId); ServiceLocator.commonInstance().getRuleService().sendEvent(StrategyImpl.BASE, o); logger.debug(EWrapperMsgGenerator.scannerDataEnd(reqId)); }
@Override public void receiveFA(final int faDataType, final String xml) { final ReceiveFA o = new ReceiveFA(faDataType, xml); ServiceLocator.commonInstance().getRuleService().sendEvent(StrategyImpl.BASE, o); logger.debug(EWrapperMsgGenerator.receiveFA(faDataType, xml)); }
@Override public void contractDetailsEnd(final int reqId) { final ContractDetailsEnd o = new ContractDetailsEnd(reqId); ServiceLocator.commonInstance().getRuleService().sendEvent(StrategyImpl.BASE, o); logger.debug(EWrapperMsgGenerator.contractDetailsEnd(reqId)); }
@Override public void execDetails(final int reqId, final Contract contract, final Execution execution) { final ExecDetails o = new ExecDetails(reqId, contract, execution); ServiceLocator.commonInstance().getRuleService().sendEvent(StrategyImpl.BASE, o); logger.debug(EWrapperMsgGenerator.execDetails(reqId, contract, execution)); }
@Override public void bondContractDetails(final int reqId, final ContractDetails contractDetails) { final ContractDetailsCommon o = new ContractDetailsCommon(reqId, contractDetails); ServiceLocator.commonInstance().getRuleService().sendEvent(StrategyImpl.BASE, o); logger.debug(EWrapperMsgGenerator.bondContractDetails(reqId, contractDetails)); }
@Override public void fundamentalData(final int reqId, final String data) { final FundamentalData o = new FundamentalData(reqId, data); ServiceLocator.commonInstance().getRuleService().sendEvent(StrategyImpl.BASE, o); logger.debug(EWrapperMsgGenerator.fundamentalData(reqId, data)); }
@Override public void currentTime(final long time) { final CurrentTime o = new CurrentTime(time); ServiceLocator.commonInstance().getRuleService().sendEvent(StrategyImpl.BASE, o); logger.debug(EWrapperMsgGenerator.currentTime(time)); }
@Override public void deltaNeutralValidation(final int reqId, final UnderComp underComp) { final DeltaNeutralValidation o = new DeltaNeutralValidation(reqId, underComp); ServiceLocator.commonInstance().getRuleService().sendEvent(StrategyImpl.BASE, o); logger.debug(EWrapperMsgGenerator.deltaNeutralValidation(reqId, underComp)); }