假設我們有這個觀察到的序列(RX)和匹配訂閱: var behaviorSubject = new BehaviorSubject<int>(3);
var sequence = behaviorSubject.Select(x => this.webservice.Call(x)).Switch();
var subscription = this.sequence.Subscribe(th
給定一個Observable,一旦調用了Subscribe,就會開始推送事件。如何將序列轉換爲IEnumerable。 在2010年,Jon Skeet寫到了他對RX的第一印象,並寫道這與我所需要的相當。 public static List<T> ToList<T>(this IObservable<T> source)
{
List<T> ret = new List<T>();
如何遍歷如果我詢問消息的類型和打印傳遞在如下(first, second, third) => new { One = first, Two = second, Three = third } 對象的anonymous type的IEnumerable的,它說:<>f__AnonymousType0 3[MtApi.MtQuote,MtApi.MtQuote,MtApi.MtQuote] //**