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
A beleza das interfaces em Go
Search
pcasarettto
July 09, 2016
Programming
320
2
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
A beleza das interfaces em Go
pcasarettto
July 09, 2016
More Decks by pcasarettto
See All by pcasarettto
Bundler
pcasarettto
1
140
Other Decks in Programming
See All in Programming
エンジニアと一緒にテストコードの設計と実装を改善した話
mototakatsu
0
250
ランチタイムLT会3周年!ランチタイムLT会を3年間続けられたお話
y0hgi
1
130
Vite+ Unified Toolchain for the Web
naokihaba
0
590
才能?センス?知らん、 続けたもん勝ちだ。-- 結婚・出産・癌を越えてなお、私がプロダクトを創り続ける理由
16bitidol
2
740
LLMによるContent Moderationの本番運用の裏側と品質担保への挑戦
suikabar
3
820
PHPで使える日時の表現と、その知り方 #frontend_phpcon_do
o0h
PRO
0
290
コンテキストの使い捨てをやめる — ビジネスルール駆動開発と miko —
ioki
0
270
その問い、本当に正しいですか?AI時代のエンジニアに必要な哲学と認知科学 / ai-philosophy-cognitive-science
minodriven
14
6.6k
Go1.27で導入されるジェネリクスメソッドでできること
mackee
0
240
はてなアカウント基盤 State of the Union
cockscomb
1
1.3k
SREの積み重ねがAI駆動開発のガードレールになった ― 7つの実践/SRE Guardrails The 7
tomoyakitaura
7
1.2k
なぜ型を書くのか? TSKaigi2026で改めて考える #tskaigi_smarthr
kajitack
0
190
Featured
See All Featured
Jess Joyce - The Pitfalls of Following Frameworks
techseoconnect
PRO
1
180
Producing Creativity
orderedlist
PRO
348
40k
How to Build an AI Search Optimization Roadmap - Criteria and Steps to Take #SEOIRL
aleyda
1
2.1k
The AI Revolution Will Not Be Monopolized: How open-source beats economies of scale, even for LLMs
inesmontani
PRO
3
3.5k
Understanding Cognitive Biases in Performance Measurement
bluesmoon
32
3k
[Rails World 2023 - Day 1 Closing Keynote] - The Magic of Rails
eileencodes
38
2.9k
Redefining SEO in the New Era of Traffic Generation
szymonslowik
1
350
The SEO identity crisis: Don't let AI make you average
varn
0
510
Chrome DevTools: State of the Union 2024 - Debugging React & Beyond
addyosmani
10
1.2k
The Impact of AI in SEO - AI Overviews June 2024 Edition
aleyda
5
1.1k
Thoughts on Productivity
jonyablonski
76
5.2k
The Art of Programming - Codeland 2020
erikaheidi
57
14k
Transcript
A beleza das interfaces em Go
Paulo Casaretto @pcasaretto
Interface
Interfaces em Go
None
None
None
io.Reader io.Writer
io.Copy io.Reader io.Writer
Reader Example: GIF Decoder
os.File deblockingReader lzw.Reader
os.File | deblockingReader | lzw.Reader
os.File deblockingReader lzw.Reader io.Reader
Usando interfaces
None
None
None
None
Two relevant Go proverbs
THE BIGGER THE INTERFACE, THE WEAKER THE ABSTRACTION
interface{} says nothing
ProTip
• https://blog.golang.org/error-handling-and-go • https://blog.golang.org/errors-are-values • https://blog.golang.org/gif-decoder-exercise- in-go-interfaces • https://go-proverbs.github.io/ Resources
Thanks!
panic(“Thanks!”)
None
None
None