Distinguishing Rx and LINQ

LINQ is brilliant at working with static collections, allowing you to use a SQL-like syntax to query and manipulate data from disparate sources. On the other hand, Rx's forté is in working with what we call future collections—that is collections that have been defined, but not yet fully populated.

LINQ requires that all the data be available when we first start writing our LINQ statements. That is, to build a new collection with LINQ, we need a starting collection.

What happens, however, if we don't have all the data? Imagine trying to write a service that operates on live, stock-trading data, in which case we want to operate on incoming streams of data in real-time. LINQ would not know what to do with this, as a stream ...

Get Programming Reactive Extensions and LINQ now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.