For those not familiar, it looks like this is the take on ideas from Reactive Extensions (Rx): http://msdn.microsoft.com/en-us/data/gg577609. I'm not sure if Rx itself has a direct predecessor or not, but it's great to see the idea taking hold in other communities. I've long suspected that there is a lot of great stuff in the .Net world that most open-source-oriented programmers never see, simply because they don't have exposure to Microsoft technology.
Here's what Rx is: The idea of a list are some items in an order (a Sequence in FP-speak). On top of a Sequence you can implement all kinds of interesting operations like map/filter/reduce.
If you look at an Event like KeyUp, you'd end up with some items, in a particular order. Thus, you realize, that events and lists really are the same thing. In fact, they're not only ostensibly the same, they are mathematically provable to be the same.
Rx therefore, gives you all the operations you can do to a list, and applies it to an event (or a callback, which is just an event that only happens once).
Comments
For those not familiar, it looks like this is the take on ideas from Reactive Extensions (Rx): http://msdn.microsoft.com/en-us/data/gg577609. I'm not sure if Rx itself has a direct predecessor or not, but it's great to see the idea taking hold in other communities. I've long suspected that there is a lot of great stuff in the .Net world that most open-source-oriented programmers never see, simply because they don't have exposure to Microsoft technology.
Here's what Rx is: The idea of a list are some items in an order (a Sequence in FP-speak). On top of a Sequence you can implement all kinds of interesting operations like map/filter/reduce.
If you look at an Event like KeyUp, you'd end up with some items, in a particular order. Thus, you realize, that events and lists really are the same thing. In fact, they're not only ostensibly the same, they are mathematically provable to be the same.
Rx therefore, gives you all the operations you can do to a list, and applies it to an event (or a callback, which is just an event that only happens once).
I enjoyed your book! Are there any plans for an updated or expanded version?
If anyone wants a simple introduction to Rx, Paul Betts (and Jesse Liberty) wrote one last year.
http://www.amazon.com/Programming-Reactive-Extensions-Jesse-...
Thanks! No plans for a 2nd edition yet, but I definitely have a lot I'd like to add.
I believe Rx is an OOish take on some older FP ideas http://en.wikipedia.org/wiki/Reactive_programming
LINQ. Someone please bring stuff like LINQ to other languages!
Edit: it appears that the MS Reactive Extensions are LINQ-y. Not sure if ReactiveCocoa is the same.