public InstrumTable(IInstrumDA da, IStorage storage, ILogger logger) { _da = da; _storage = storage; _logger = logger; _ticker_instrum = new Dictionary <string, Instrum>(); _insID_instrum = new Dictionary <int, Instrum>(); }
public ImportLeech(IInstrumDA instrumDA, IAccountDA accountDA, IConfig config, ITickHistoryDA tickHistoryDA, IReplicationBL replBL) { _instrumDA = instrumDA; _accountDA = accountDA; _config = config; _tickHistoryDA = tickHistoryDA; _replBL = replBL; _instrum_rid_lid = new Dictionary <int, int>(); _account_rid_lid = new Dictionary <int, int>(); _stoporder_rid_lid = new Dictionary <int, int>(); _order_rid_lid = new Dictionary <int, int>(); _trade_rid_lid = new Dictionary <int, int>(); }
public PositionTest() { DbContextOptionsBuilder <DaContext> builder = new DbContextOptionsBuilder <DaContext>(); builder.UseNpgsql("Username=postgres;Password=123;Host=localhost;Port=5432;Database=pulxer_test"); _options = builder.Options; _insDA = new InstrumDA(_options); _accountDA = new AccountDA(_options); _positionDA = new PositionDA(_options); // создание var gazp = _insDA.GetInstrum(0, "GAZP"); if (gazp == null) { _gazpID = _insDA.InsertInstrum("GAZP", "Газпром", "Газпром", 10, 2, 1); } else { _gazpID = gazp.InsID; } var lkoh = _insDA.GetInstrum(0, "LKOH"); if (lkoh == null) { _lkohID = _insDA.InsertInstrum("LKOH", "Лукойл", "Лукойл", 1, 0, 0); } else { _lkohID = lkoh.InsID; } _accountID = _accountDA.CreateAccount("", "", 0, false, Common.Data.AccountTypes.Test).AccountID; }
public SyncBL(IInstrumDA instrumDA) { _instrumDA = instrumDA; }
public InstrumBL(IInstrumDA instrumDA, IInsStoreDA insStoreDA) { _instrumDA = instrumDA; _insStoreDA = insStoreDA; }
public InstrumCtrl(IConsole console, IInstrumDA instrumDA) { _console = console; _instrumDA = instrumDA; }