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
SOLID - Dependency inversion principle
Search
Amanda
October 09, 2018
Technology
0
74
SOLID - Dependency inversion principle
Amanda
October 09, 2018
Tweet
Share
More Decks by Amanda
See All by Amanda
Lessons Learned From an Elixir OTP Project
amandasposito
2
67
Aprendizados de um projeto Elixir OTP
amandasposito
4
560
Como concorrência funciona em Elixir?
amandasposito
1
220
Programação Funcional & Elixir
amandasposito
3
120
Ecto, você sabe o que é ?
amandasposito
4
240
Novidades no Rails 5
amandasposito
0
96
Rails Engines & RSpec
amandasposito
0
210
Elixir e Phoenix
amandasposito
3
560
Elixir em 5 minutos
amandasposito
1
91
Other Decks in Technology
See All in Technology
実践!カスタムインストラクション&スラッシュコマンド
puku0x
0
510
テストを軸にした生き残り術
kworkdev
PRO
0
210
Webアプリケーションにオブザーバビリティを実装するRust入門ガイド
nwiizo
7
880
5分でカオスエンジニアリングを分かった気になろう
pandayumi
0
260
新規プロダクトでプロトタイプから正式リリースまでNext.jsで開発したリアル
kawanoriku0
1
190
サラリーマンの小遣いで作るtoCサービス - Cloudflare Workersでスケールする開発戦略
shinaps
2
470
CDK CLIで使ってたあの機能、CDK Toolkit Libraryではどうやるの?
smt7174
4
190
20250912_RPALT_データを集める→とっ散らかる問題_Obsidian紹介
ratsbane666
0
100
スマートファクトリーの第一歩 〜AWSマネージドサービスで 実現する予知保全と生成AI活用まで
ganota
2
310
Evolución del razonamiento matemático de GPT-4.1 a GPT-5 - Data Aventura Summit 2025 & VSCode DevDays
lauchacarro
0
210
20250913_JAWS_sysad_kobe
takuyay0ne
2
250
Snowflake×dbtを用いたテレシーのデータ基盤のこれまでとこれから
sagara
0
120
Featured
See All Featured
個人開発の失敗を避けるイケてる考え方 / tips for indie hackers
panda_program
113
20k
Fireside Chat
paigeccino
39
3.6k
Facilitating Awesome Meetings
lara
55
6.5k
The MySQL Ecosystem @ GitHub 2015
samlambert
251
13k
Six Lessons from altMBA
skipperchong
28
4k
How To Stay Up To Date on Web Technology
chriscoyier
790
250k
Become a Pro
speakerdeck
PRO
29
5.5k
Code Review Best Practice
trishagee
71
19k
Put a Button on it: Removing Barriers to Going Fast.
kastner
60
4k
Distributed Sagas: A Protocol for Coordinating Microservices
caitiem20
333
22k
Templates, Plugins, & Blocks: Oh My! Creating the theme that thinks of everything
marktimemedia
31
2.5k
RailsConf & Balkan Ruby 2019: The Past, Present, and Future of Rails at GitHub
eileencodes
139
34k
Transcript
SOLID Dependency Inversion Principle
O que é? Onde vive?
Falando um pouco de SOLID...
Imagine um cenário
Temos um software novo para escrever
No começo é aquela alegria
None
As mudanças são simples, a velocidade é boa
None
None
Fragilidade "Tendência do software de quebrar em vários lugares sempre
que é alterado. Geralmente em lugares não relacionados conceitualmente com o local da mudança."
Rigidez "Tendência do software de ser difícil de mudar. Qualquer
mudança gera várias mudanças em sequência." https://fi.ort.edu.uy/innovaportal/file/2032/1/design_principles.pdf
"Abstrações não devem depender de detalhes. Detalhes devem depender de
abstrações."
None
class Copier def self.copy reader = KeyboardReader.new writer = Printer.new
keystrokes = reader.read_until_eof writer.write(keystrokes) end end
class Copier def initialize(reader, writer) @reader = reader @writer =
writer end def copy @writer.write(@reader.read_until_eof) end end
None