public SignalController(ILogger <SignalController> logger,
                         ISignalRepository signalRepository,
                         ISignalSourceRepository signalSourceRepository,
                         ISignalTypeRepository signalTypeRepository)
 {
     this.logger                 = logger;
     this.signalRepository       = signalRepository;
     this.signalSourceRepository = signalSourceRepository;
     this.signalTypeRepository   = signalTypeRepository;
 }
示例#2
0
        public Signal[] GetSignals()
        {
            return(ExecuteFaultHandledOperation(() =>
            {
                ISignalRepository signalRepository = _DataRepositoryFactory.GetDataRepository <ISignalRepository>();
                IEnumerable <Signal> signals = signalRepository.Get();

                return signals.ToArray();
            }));
        }
示例#3
0
        public Signal GetSignal(int signalId)
        {
            return(ExecuteFaultHandledOperation(() =>
            {
                ISignalRepository signalRepository = _DataRepositoryFactory.GetDataRepository <ISignalRepository>();
                Signal signal = signalRepository.Get(signalId);

                return signal;
            }));
        }
示例#4
0
 public SignalsController(
     IUnitOfWork unitOfWork,
     ILotRepository lotRepository,
     ISignalRepository signalRepository,
     ILotEventDispatcher lotEventDispatcher)
 {
     this.unitOfWork = unitOfWork;
     this.lotRepository = lotRepository;
     this.signalRepository = signalRepository;
     this.lotEventDispatcher = lotEventDispatcher;
 }
示例#5
0
        public Signal UpdateSignal(Signal signal)
        {
            return(ExecuteFaultHandledOperation(() =>
            {
                ISignalRepository signalRepository = _DataRepositoryFactory.GetDataRepository <ISignalRepository>();

                Signal updatedEntity = null;

                if (signal.SignalID == 0)
                {
                    updatedEntity = signalRepository.Add(signal);
                }
                else
                {
                    updatedEntity = signalRepository.Update(signal);
                }

                return updatedEntity;
            }));
        }
示例#6
0
 public StudentSignalsEndpointController(IConfiguration configuration, ISignalRepository repository)
 {
     _configuration = configuration;
     _repository    = repository;
 }
示例#7
0
        public UnitOfWork(ITimeIntervalRepository timeIntervals, IBrokerTimeIntervalRepository brokerTimeIntervals, IBrokerRepository brokers, IInstrumentNameRepository instrumentNames, IBrokerInstrumentRepository brokerInstruments, IPriceEntryRepository priceEntries, IScreenerEntryMappingRepository screenerEntryMappings, IScreenerEntryTypeRepository screenerEntryTypes, IBrokerInstrumentScreenerTypeRepository brokerInstrumentScreenerTypes, IScreenerTypeRepository screenerTypes, IBrokerSymbolRepository brokerSymbols, ICurrencyRepository currencies, IExchangeRepository exchanges, IInstrumentTypeRepository instrumentTypes, IScreenerRepository screeners, IScreenerLineRepository screenerLines, IScreenerReferenceImageRepository screenerReferenceImages, IScreenerEntryRepository screenerEntries, IIndicatorEntryRepository indicatorEntries, ITradeRepository trades, ITradeStepRepository tradeSteps, IOrderRepository orders, ISignalRepository signals, ISignalStepRepository signalSteps, IStopLossRuleRepository stopLossRules, IExitRuleRepository exitRules)
        {
            this.TimeIntervals = timeIntervals;
            this.BrokerTimeIntervals = brokerTimeIntervals;
            this.Brokers = brokers;
            this.InstrumentNames = instrumentNames;
            this.BrokerInstruments = brokerInstruments;
            this.PriceEntries = priceEntries;
            this.ScreenerEntryMappings = screenerEntryMappings;
            this.ScreenerEntryTypes = screenerEntryTypes;
            this.BrokerInstrumentScreenerTypes = brokerInstrumentScreenerTypes;
            this.ScreenerTypes = screenerTypes;
            this.BrokerSymbols = brokerSymbols;
            this.Currencies = currencies;
            this.Exchanges = exchanges;
            this.InstrumentTypes = instrumentTypes;
            this.Screeners = screeners;
            this.ScreenerLines = screenerLines;
            this.ScreenerReferenceImages = screenerReferenceImages;
            this.ScreenerEntries = screenerEntries;
            this.IndicatorEntries = indicatorEntries;
            this.Trades = trades;
            this.TradeSteps = tradeSteps;
            this.Orders = orders;
            this.Signals = signals;
            this.SignalSteps = signalSteps;
            this.StopLossRules = stopLossRules;
            this.ExitRules = exitRules;

        }
示例#8
0
 public SignalController(ITrainControlCentreService controlService, ISignalRepository signalRepository)
 {
     this.controlService   = controlService;
     this.signalRepository = signalRepository;
 }