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
Event-Driven Programming at Android (but not Rx...
Search
Enrique López Mañas
November 29, 2015
Programming
0
890
Event-Driven Programming at Android (but not RxJava!)
Presentation at the DevFest Istanbul
Enrique López Mañas
November 29, 2015
Tweet
Share
More Decks by Enrique López Mañas
See All by Enrique López Mañas
Composifying Your Not-Compose Code
kikoso
0
2
Guardrails and Sanity Checks: Verifying LLM Input and Output for Developers
kikoso
0
28
KMP_for_Swift.pdf
kikoso
0
51
Android Benchmarking and other stories
kikoso
0
280
KMP for Mobile Developers
kikoso
0
70
Diving into Coroutines
kikoso
1
74
K/N for mobile developers (including libraries' snippets)
kikoso
0
94
Kotlin/Native for Multiplatform development
kikoso
0
68
TensorFlow for Mobile Developers
kikoso
0
21
Other Decks in Programming
See All in Programming
実践Claude Code:20の失敗から学ぶAIペアプログラミング
takedatakashi
15
5.5k
AI駆動で0→1をやって見えた光と伸びしろ
passion0102
1
390
3年ぶりにコードを書いた元CTOが Claude Codeと30分でMVPを作った話
maikokojima
0
540
CSC305 Lecture 08
javiergs
PRO
0
230
The Past, Present, and Future of Enterprise Java
ivargrimstad
0
220
オープンソースソフトウェアへの解像度🔬
utam0k
16
3k
CSC509 Lecture 06
javiergs
PRO
0
260
Foundation Modelsを実装日本語学習アプリを作ってみた!
hypebeans
0
120
CSC509 Lecture 04
javiergs
PRO
0
300
登壇は dynamic! な営みである / speech is dynamic
da1chi
0
340
いま中途半端なSwift 6対応をするより、Default ActorやApproachable Concurrencyを有効にしてからでいいんじゃない?
yimajo
2
440
非同期jobをtransaction内で 呼ぶなよ!絶対に呼ぶなよ!
alstrocrack
0
980
Featured
See All Featured
Making Projects Easy
brettharned
120
6.4k
XXLCSS - How to scale CSS and keep your sanity
sugarenia
248
1.3M
Being A Developer After 40
akosma
91
590k
Understanding Cognitive Biases in Performance Measurement
bluesmoon
31
2.7k
Raft: Consensus for Rubyists
vanstee
140
7.1k
What's in a price? How to price your products and services
michaelherold
246
12k
I Don’t Have Time: Getting Over the Fear to Launch Your Podcast
jcasabona
33
2.5k
Writing Fast Ruby
sferik
629
62k
Practical Orchestrator
shlominoach
190
11k
BBQ
matthewcrist
89
9.8k
RailsConf 2023
tenderlove
30
1.3k
Visualization
eitanlees
149
16k
Transcript
Event-Driven Programming Not Reactive! Enrique López Mañas Google Developer Expert
& IT Consultor
#dfist Ego Slide • IT Consultor • Google Developer Expert
• @eenriquelopez
#dfist Similar programming paradigms • Event-Driven • Observer pattern •
Pub/Sub pattern • Dataflow programming
#dfist Reactive • Everything is a flow • Reactive is
more declarative, less imperative • Reactive is local, Event-Driven is global
#dfist Event-Driven • Actions (events) • Can decouple and communicate
#dfist Event-Driven
#dfist Event-Driven
#dfist Event-Driven • Greenbus • Otto • TinyBus
#dfist Event-Driven
#dfist Event-Driven
#dfist EventBus vs. BroadcastReceiver • BroadcastReceiver/Intent System • EventBus uses
standard Java classes as events • Do not have to set up intent extras, implement broadcast, extract.. • EventBus: much lower overhead
#dfist Event-Driven • Event-Bus • Event • Subscriber • Publisher
#dfist Event-Driven
#dfist Event-Driven EventBus.getDefault().register(this); EventBus.getDefault().unregister(this);
#dfist Event-Driven public void onEvent(AttachFragmentEvent event) { getFragmentManager().beginTransaction().replace(R.id.container, event.getFragment()).addToBackStack(null).commit(); }
#dfist Event-Driven public void onEvent(ShowSecondFragment event){ EDEventBus.postEvent(new AttachFragmentEvent(new SecondFragment())); }
#dfist Event-Driven • StickyEvents
#dfist Event-Driven • Model • View • Presenter
#dfist Event-Driven
#dfist Event-Driven • Android: not pure MVP • User Interface,
Views • Classes that inflates UI (Fragment, Activities)
#dfist Event-Driven
#dfist Model View Presenter • https://github.com/kikoso/Event-Bus-Architecture
#dfist Event-Driven WidgetObservable.text(email) .map(textChangedMap) .map(validateInputs) .startWith(false) .distinctUntilChanged() .subscribe(ViewActions.setEnabled(submit));
#dfist Event-Driven • Loose decouple • Intercommunication • Scalability •
Testability
#dfist Event-Driven • Nested Events • Treating Producers Like Synchronous
Getters • Debugging • Classes explosion • Data in Events
#dfist I want your feedback! http://bit.ly/devFestFeedback
#dfist