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
Single responsibility principle
Search
Grzegorz Wilczyński
November 12, 2012
Programming
2
190
Single responsibility principle
Single responsibility principle
Grzegorz Wilczyński
November 12, 2012
Tweet
Share
More Decks by Grzegorz Wilczyński
See All by Grzegorz Wilczyński
REWRITE'EM ALL
gwilczynski
2
460
Chain made out of coins - smart introduction to blockchain
gwilczynski
0
92
WebComponents or shadow side of the Doom
gwilczynski
0
48
clean code
gwilczynski
0
130
git scm in one hour
gwilczynski
0
110
Productivity for Programmers
gwilczynski
3
200
Git branching model for TAPTeam
gwilczynski
0
920
JS design patterns
gwilczynski
6
360
Other Decks in Programming
See All in Programming
menu基盤チームによるGoogle Cloudの活用事例~Application Integration, Cloud Tasks編~
yoshifumi_ishikura
0
110
ドメインイベント増えすぎ問題
h0r15h0
2
350
ある日突然あなたが管理しているサーバーにDDoSが来たらどうなるでしょう?知ってるようで何も知らなかったDDoS攻撃と対策 #phpcon.2024
akase244
1
140
tidymodelsによるtidyな生存時間解析 / Japan.R2024
dropout009
1
790
「Chatwork」Android版アプリを 支える単体テストの現在
okuzawats
0
180
MCP with Cloudflare Workers
yusukebe
2
220
Spatial Rendering for Apple Vision Pro
warrenm
0
110
「とりあえず動く」コードはよい、「読みやすい」コードはもっとよい / Code that 'just works' is good, but code that is 'readable' is even better.
mkmk884
3
480
命名をリントする
chiroruxx
1
410
htmxって知っていますか?次世代のHTML
hiro_ghap1
0
340
Effective Signals in Angular 19+: Rules and Helpers @ngbe2024
manfredsteyer
PRO
0
140
ChatGPT とつくる PHP で OS 実装
memory1994
PRO
2
110
Featured
See All Featured
Building Better People: How to give real-time feedback that sticks.
wjessup
365
19k
Sharpening the Axe: The Primacy of Toolmaking
bcantrill
38
1.9k
The Success of Rails: Ensuring Growth for the Next 100 Years
eileencodes
44
6.9k
Designing for humans not robots
tammielis
250
25k
It's Worth the Effort
3n
183
28k
Visualizing Your Data: Incorporating Mongo into Loggly Infrastructure
mongodb
44
9.3k
Become a Pro
speakerdeck
PRO
26
5k
Improving Core Web Vitals using Speculation Rules API
sergeychernyshev
0
98
jQuery: Nuts, Bolts and Bling
dougneiner
61
7.5k
Fontdeck: Realign not Redesign
paulrobertlloyd
82
5.3k
Principles of Awesome APIs and How to Build Them.
keavy
126
17k
Fashionably flexible responsive web design (full day workshop)
malarkey
405
66k
Transcript
Design patterns: The Single-Responsibility Principle Grzegorz Wilczyński 11th november 2012
SOLID The principles when applied together intend to make it
more likely that a programmer will create a system that is easy to maintain and extend over time. http://en.wikipedia.org/wiki/Solid_(object-oriented_design)
SOLID Single responsibility Open-closed Liskov substitution Interface segregation Dependency inversion
http://en.wikipedia.org/wiki/Solid_(object-oriented_design)
BIBLE http://www.amazon.com/Agile-Principles-Patterns-Practices-C/dp/0131857258
Rule #1 A class should have only one reason to
change. "Agile Principles, Patterns, and Practices in C#" Robert C. Martin
Rule #2 A class should have only one reason to
change. "Agile Principles, Patterns, and Practices in C#" Robert C. Martin
So please don't... http://3.bp.blogspot.com/-FQZ4VT_gbRY/T8RvXLTPWMI/AAAAAAAABP0/JCckSpENM88/s640/SingleResponsibilityPrinciple.jpg
Step 1 http://www.remondo.net/wp-content/uploads/2012/03/SingleResponsibilityPrincipleRadio.png
Step 2 http://www.remondo.net/wp-content/uploads/2012/03/SingleResponsibilityPrincipleRadioManagers.png
Homework $ git branch gw-solid-1 end time: 16.11.2012