Exemplo n.º 1
0
 public QuoteBookStruct(QuoteBook newQuote)
 {
     Instr   = (InstrInfo[])newQuote.Instr.Clone();
     BidBk   = newQuote.BidBk;
     AskBk   = newQuote.AskBk;
     AskExch = newQuote.AskExch;
     BidExch = newQuote.BidExch;
     NumAsk  = newQuote.NumAsk;
     NumBid  = newQuote.NumBid;
     TS      = newQuote.TS;
     PartID  = newQuote.PartID;
     Mod     = newQuote.Mod;
     TEST_TIMESTAMP_TICKS = newQuote.TEST_TIMESTAMP_TICKS;
     InstrumentName       = Utilities.InstrToStr(Instr);
 }
Exemplo n.º 2
0
        public void GetSpreadQuote(InstrInfo[] instruments, IMarketDataConsumer <QuoteBook> cons)
        {
            if (instruments.Length > 1)
            {
                Console.WriteLine("Getting spread quote...");
                FastOMS.Data_Structures.QuoteBook qb = new Data_Structures.QuoteBook();

                while (!_spreadInitialQuotes.TryGetValue(Utilities.InstrToStr(instruments), out qb))
                {
                    Thread.Sleep(1000);
                    Console.WriteLine("waiting for spread quote");
                }

                cons.NewDataHandler(qb);
            }
        }