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
Monads na prática - QConSP 2014
Search
Breno Ferreira
April 09, 2014
Programming
0
91
Monads na prática - QConSP 2014
Breno Ferreira
April 09, 2014
Tweet
Share
More Decks by Breno Ferreira
See All by Breno Ferreira
TDC Globo Sistemas Distribuídos
brenoferreira
1
49
Trabalho Remoto TDC Globo 2020
brenoferreira
1
69
Immutable Da
brenoferreira
0
38
Remote Work
brenoferreira
0
45
Fun with Types
brenoferreira
0
180
RxJava
brenoferreira
1
330
.NET Além do Mundo Microsoft
brenoferreira
0
63
TDC2013 - Programação assíncrona com Javascript
brenoferreira
1
490
TDD com Javascript
brenoferreira
1
430
Other Decks in Programming
See All in Programming
React 19でお手軽にCSS-in-JSを自作する
yukukotani
5
560
週次リリースを実現するための グローバルアプリ開発
tera_ny
1
1.2k
CQRS+ES の力を使って効果を感じる / Feel the effects of using the power of CQRS+ES
seike460
PRO
0
240
traP の部内 ISUCON とそれを支えるポータル / PISCON Portal
ikura_hamu
0
180
非ブラウザランタイムとWeb標準 / Non-Browser Runtimes and Web Standards
petamoriken
0
430
[JAWS-UG横浜 #80] うわっ…今年のServerless アップデート、少なすぎ…?
maroon1st
0
100
PHPで作るWebSocketサーバー ~リアクティブなアプリケーションを知るために~ / WebSocket Server in PHP - To know reactive applications
seike460
PRO
2
770
Асинхронность неизбежна: как мы проектировали сервис уведомлений
lamodatech
0
1.3k
『改訂新版 良いコード/悪いコードで学ぶ設計入門』活用方法−爆速でスキルアップする!効果的な学習アプローチ / effective-learning-of-good-code
minodriven
28
4.1k
見えないメモリを観測する: PHP 8.4 `pg_result_memory_size()` とSQL結果のメモリ管理
kentaroutakeda
0
930
責務を分離するための例外設計 - PHPカンファレンス 2024
kajitack
9
2.4k
functionalなアプローチで動的要素を排除する
ryopeko
1
200
Featured
See All Featured
GraphQLとの向き合い方2022年版
quramy
44
13k
Code Review Best Practice
trishagee
65
17k
Become a Pro
speakerdeck
PRO
26
5.1k
Done Done
chrislema
182
16k
Creating an realtime collaboration tool: Agile Flush - .NET Oxford
marcduiker
26
1.9k
JavaScript: Past, Present, and Future - NDC Porto 2020
reverentgeek
47
5.1k
We Have a Design System, Now What?
morganepeng
51
7.3k
Easily Structure & Communicate Ideas using Wireframe
afnizarnur
192
16k
It's Worth the Effort
3n
183
28k
Why You Should Never Use an ORM
jnunemaker
PRO
54
9.1k
Build your cross-platform service in a week with App Engine
jlugia
229
18k
Stop Working from a Prison Cell
hatefulcrawdad
267
20k
Transcript
MONADS NA PRÁTICA @breno_ferreira Breno Ferreira
PROGRAMAÇÃO FUNCIONAL É ASSUSTADOR Functors Monoids Catamorphism MONAD
PROGRAMAÇÃO FUNCIONAL É POUCO FAMILIAR Functors Monoids Catamorphism MONAD
PROGRAMAÇÃO FUNCIONAL É POUCO FAMILIAR Mappables Monoids Catamorphism MONAD
PROGRAMAÇÃO FUNCIONAL É POUCO FAMILIAR Mappables Monoids Aggregatables MONAD
PROGRAMAÇÃO FUNCIONAL É POUCO FAMILIAR Mappables Composables Aggregatables MONAD
PROGRAMAÇÃO FUNCIONAL É POUCO FAMILIAR Mappables Composables Aggregatables Chainable
ORIENTAÇÃO A OBJETO É ASSUSTADOR! Polimorfismo Herança Variancia interfaces SOLID
SRP, OCP, LSP, ISP, DIP IoC, DI, MVC, ORM, GoF, PoEAA…
ORIENTAÇÃO A OBJETO É ASSUSTADOR! Polimorfismo Herança Variancia interfaces SOLID
SRP, OCP, LSP, ISP, DIP IoC, DI, MVC, ORM, GoF, PoEAA…
MAS O QUE É UMA MONAD?
MAS O QUE É UMA MONAD? A monad is just
a monoid in the category of endofunctors. James Iry http://james-iry.blogspot.com.br/2009/05/brief-incomplete-and-mostly-wrong.html
DEFINIÇÃO DE UMA MONAD type Monad return :: a ->
m a (>>=) :: m a -> (a -> m b) -> m b
TRADUÇÃO interface Monad<A> static Create(value: A): Monad<A> flatMap(mapper: A ->
Monad<B>): Monad<B>
MAS PARA QUE AS MONADS SÃO ÚTEIS? • Nulls •
Exceptions • Assincronia • Reactive Programming • Mutable state • etc…
HTTPS://GITHUB.COM/BRENOFERREIRA/CSHARP.FUN
OBRIGADO! @breno_ferreira