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
Duck Typing
Search
Javier Cervantes
May 30, 2014
Programming
0
82
Duck Typing
Based on chapter #5 of POODR.
Given at rubygdl.org.
Javier Cervantes
May 30, 2014
Tweet
Share
More Decks by Javier Cervantes
See All by Javier Cervantes
Continuous Delivery para todos @ SGNext
solojavier
0
100
Gobot.io y el internet de las cosas
solojavier
0
110
Deliberate Practice - Lightning Talk
solojavier
0
140
Golang - WePow Talks
solojavier
0
60
Server Provisioning and Configuration
solojavier
0
64
Evolución Robótica
solojavier
0
49
Re-evolución robótica
solojavier
0
84
Artoo : Ruby on robots
solojavier
0
110
Las pruebas primero
solojavier
0
57
Other Decks in Programming
See All in Programming
uniqueパッケージの内部実装を支えるweak pointerの話
magavel
0
920
タスクの特性や不確実性に応じた最適な作業スタイルの選択(ペアプロ・モブプロ・ソロプロ)と実践 / Optimal Work Style Selection: Pair, Mob, or Solo Programming.
honyanya
3
140
階層構造を表現するデータ構造とリファクタリング 〜1年で10倍成長したプロダクトの変化と課題〜
yuhisatoxxx
3
920
CSC509 Lecture 05
javiergs
PRO
0
300
CSC305 Lecture 04
javiergs
PRO
0
250
2025年版 サーバーレス Web アプリケーションの作り方
hayatow
23
25k
10年もののAPIサーバーにおけるCI/CDの改善の奮闘
mbook
0
780
GitHub Actions × AWS OIDC連携の仕組みと経緯を理解する
ota1022
0
240
The Past, Present, and Future of Enterprise Java
ivargrimstad
0
140
ABEMAモバイルアプリが Kotlin Multiplatformと歩んだ5年 ─ 導入と運用、成功と課題 / iOSDC 2025
akkyie
0
330
AIエージェント時代における TypeScriptスキーマ駆動開発の新たな役割
bicstone
4
1.5k
Pythonスレッドとは結局何なのか? CPython実装から見るNoGIL時代の変化
curekoshimizu
4
1.3k
Featured
See All Featured
"I'm Feeling Lucky" - Building Great Search Experiences for Today's Users (#IAC19)
danielanewman
229
22k
Bootstrapping a Software Product
garrettdimon
PRO
307
110k
Dealing with People You Can't Stand - Big Design 2015
cassininazir
367
27k
Building Adaptive Systems
keathley
43
2.8k
Cheating the UX When There Is Nothing More to Optimize - PixelPioneers
stephaniewalter
285
14k
[RailsConf 2023 Opening Keynote] The Magic of Rails
eileencodes
31
9.7k
How to train your dragon (web standard)
notwaldorf
96
6.3k
Rails Girls Zürich Keynote
gr2m
95
14k
Designing for humans not robots
tammielis
254
25k
Fashionably flexible responsive web design (full day workshop)
malarkey
407
66k
Practical Tips for Bootstrapping Information Extraction Pipelines
honnibal
PRO
23
1.5k
Writing Fast Ruby
sferik
629
62k
Transcript
Duck Typing @ruby_gdl << @solojavier # Based on chapter 5
of book poodr.com
What is Duck Typing "If an object quacks like a
duck and walks like a duck, then it's a duck" Technique that help us reduce cost of change Public interfaces not tied to any specific class Duck typed objects are chameleons that are defined more by their behaviour than by their class
Learning by example
None
None
requirements.change!
None
None
code_design.add(:duck_typing)
None
None
None
Summary Duck typing detaches public interfaces from classes It creates
virtual types defined by behaviour Depending on this abstractions increases flexibility This will make your application easier to change