Frappé: Functional Reactive Programming in Java

Functional Reactive Programming (FRP) is a declarative programming model for constructing interactive applications based on a continuous model of time. FRP programs are described in terms of behaviors (continuous, time-varying, reactive values), and events (conditions that occur at discrete points in time). This paper presents FrappE, an implementation of FRP in the Java progamming language. The primary contribution of FrappE is its integration of the FRP event/behavior model with the Java Beans event/property model. At the interface level, any Java Beans component may be used as a source or sink for the FRP event and behavior combinators. This provides a mechanism for extending FrappE with new kinds of I/O connections and allows FRP to be used as a high-level declarative model for composing applications from Java Beans components. At the implementation level, the Java Beans event model is used internally by FrappE to propagate FRP events and changes to FRP behaviors. This allows FrappE applications to be packaged as Java Beans components for use in other applications, and yields an implementation of FRP well-suited to the requirements of event-driven applications (such as graphical user interfaces).

[1]  Paul Hudak,et al.  Modular domain specific languages and tools , 1998, Proceedings. Fifth International Conference on Software Reuse (Cat. No.98TB100203).

[2]  Simon L. Peyton Jones,et al.  Report on the programming language Haskell: a non-strict, purely functional language version 1.2 , 1992, SIGP.

[3]  Meurig Sage FranTk - a declarative GUI language for Haskell , 2000, ICFP '00.

[4]  Conal Elliott,et al.  An Embedded Modeling Language Approach to Interactive 3D and Multimedia Animation , 1999, IEEE Trans. Software Eng..

[5]  Simon L. Peyton Jones,et al.  Calling hell from heaven and heaven from hell , 1999, ICFP '99.

[6]  Paul Hudak,et al.  Functional reactive animation , 1997, ICFP '97.

[7]  Conal Elliott,et al.  Declarative event-oriented programming , 2000, PPDP '00.

[8]  Simon L. Peyton Jones,et al.  H/Direct: a binary foreign language interface for Haskell , 1998, ICFP '98.

[9]  Vincent J. Hardy Java 2D API Graphics , 1999 .

[10]  Martin Odersky,et al.  Making the future safe for the past: adding genericity to the Java programming language , 1998, OOPSLA '98.

[11]  Simon L. Peyton Jones,et al.  Scripting COM components in Haskell , 1998, Proceedings. Fifth International Conference on Software Reuse (Cat. No.98TB100203).

[12]  Conal Elliott,et al.  Functional Implementations of Continuos Modeled Animation , 1998, PLILP/ALP.

[13]  Paul Hudak The Haskell School of Expression: Learning Functional Programming through Multimedia , 1999 .

[14]  Ralf Hinze,et al.  Haskell 98 — A Non−strict‚ Purely Functional Language , 1999 .