O'Reilly logo

Functional Reactive Programming by Stephen Blackheath Anthony Jones

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 2. Core FRP

This chapter covers

  • Stream and Cell types
  • map, merge, hold, snapshot, filter, lift, never, and constant primitives
  • Forward references with StreamLoop and CellLoop
  • Making an accumulator with hold and snapshot

To demonstrate the core principles of FRP, in the first few chapters of this book we’ll use our Sodium library in Java. We chose Java because it has static typing (which works well with FRP), and the syntax turns out to be quite nice. We’re trying to teach the concepts of FRP, not the implementation details of specific systems. We designed Sodium to embody those basic concepts as minimally and completely as possible. Sodium and Java are just a convenient vehicle for this purpose; we hope you won’t see this book ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required