static Quote Parse(string text) { var stream = new TextStream(); stream.Initialize(text); var lrpQuote = stream.ReadQuote("quote"); var bids = new QuoteEntry[lrpQuote.Bids.Length]; var asks = new QuoteEntry[lrpQuote.Asks.Length]; for (int index = 0; index < lrpQuote.Bids.Length; ++index) { bids[index] = new QuoteEntry(lrpQuote.Bids[index].Price, lrpQuote.Bids[index].Volume); } for (int index = 0; index < lrpQuote.Asks.Length; ++index) { asks[index] = new QuoteEntry(lrpQuote.Asks[index].Price, lrpQuote.Asks[index].Volume); } var result = new Quote(lrpQuote.Symbol, lrpQuote.CreatingTime, bids, asks); return(result); }