Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Implementing Functional Reactive Programming in...
Search
Sponsored
·
SiteGround - Reliable hosting with speed, security, and support you can count on.
→
oetzi
February 21, 2012
Programming
1
230
Implementing Functional Reactive Programming in Scala - Progress Presentation
A presentation showing the capabilities of my current FRP framework
oetzi
February 21, 2012
Tweet
Share
More Decks by oetzi
See All by oetzi
Implementing Functional Reactive Programming in Scala - Final Presentation
oetzi
1
98
Implementing Functional Reactive Programming in Scala - Project Proposal
oetzi
1
180
Other Decks in Programming
See All in Programming
Gemini for developers
meteatamel
0
110
AI時代のキャリアプラン「技術の引力」からの脱出と「問い」へのいざない / tech-gravity
minodriven
22
7.7k
AIによる開発の民主化を支える コンテキスト管理のこれまでとこれから
mulyu
3
1.5k
Honoを使ったリモートMCPサーバでAIツールとの連携を加速させる!
tosuri13
1
190
Rust 製のコードエディタ “Zed” を使ってみた
nearme_tech
PRO
0
250
AIエージェントのキホンから学ぶ「エージェンティックコーディング」実践入門
masahiro_nishimi
7
990
Lambda のコードストレージ容量に気をつけましょう
tattwan718
0
170
humanlayerのブログから学ぶ、良いCLAUDE.mdの書き方
tsukamoto1783
0
200
Best-Practices-for-Cortex-Analyst-and-AI-Agent
ryotaroikeda
1
120
AI Schema Enrichment for your Oracle AI Database
thatjeffsmith
0
350
プロダクトオーナーから見たSOC2 _SOC2ゆるミートアップ#2
kekekenta
0
240
[KNOTS 2026登壇資料]AIで拡張‧交差する プロダクト開発のプロセス および携わるメンバーの役割
hisatake
0
320
Featured
See All Featured
技術選定の審美眼(2025年版) / Understanding the Spiral of Technologies 2025 edition
twada
PRO
117
110k
Building AI with AI
inesmontani
PRO
1
720
Game over? The fight for quality and originality in the time of robots
wayneb77
1
120
DevOps and Value Stream Thinking: Enabling flow, efficiency and business value
helenjbeal
1
120
Leveraging Curiosity to Care for An Aging Population
cassininazir
1
170
コードの90%をAIが書く世界で何が待っているのか / What awaits us in a world where 90% of the code is written by AI
rkaga
60
42k
The AI Revolution Will Not Be Monopolized: How open-source beats economies of scale, even for LLMs
inesmontani
PRO
3
3.1k
SEO in 2025: How to Prepare for the Future of Search
ipullrank
3
3.3k
Designing for Performance
lara
611
70k
Designing Dashboards & Data Visualisations in Web Apps
destraynor
231
54k
Collaborative Software Design: How to facilitate domain modelling decisions
baasie
0
150
Speed Design
sergeychernyshev
33
1.5k
Transcript
Implementing Functional Reactive Programming in
Remember this?
Behaviour[T] = Time => T
Event[T] = Stream[(Time, T)]
Lets use them...
val beh = new Behaviour(time => Color.red)
beh.at(now)
beh.at(now) def now = System.currentTimeMillis
beh.map(val => val.toString)
val event = new Event[Boolean]
beh.until(event, beh1)
“Hi!”.toggle(event, “Bye!”)
“Hi!”.toggle(event, “Bye!”) ?
implicit def lift[T](value : T) = { new Behaviour(time =>
value) }
implicit def lift[T](value : T) = { new Behaviour(time =>
value) }
So Far:
So Far: - Core FRP: Behaviour/Event
So Far: - Core FRP: Behaviour/Event - UI Framework
So Far: - Core FRP: Behaviour/Event - UI Framework -
I/O Framework
Everything: http://github.com/oetzi/echo
An example...
None
val playButton = Button(button => "Play".toggle(button.click, "Pause"))
val slider = Slider()
val playing = false.toggle(playButton.click, true) val song = new Song(file,
playing, slider.value)
val anim = song.volume.map1(width) { (v, w) => math.min(v *
(w / 50F), w) } val bouncer = Block(anim, height - 70, Color.green)
val frame = Frame(width, height, List( bouncer, slider, playButton ))
What if something goes wrong?
class Dangerous extends Breakable { dangerous { () => break_everything()
} }
class Dangerous extends Breakable { dangerous { () => break_everything()
} } val danger = new Dangerous() val err : Event[Exception] = danger.errors
DOING IT LIVE
Thank You!