News Feed
Sections




News Archive
Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

William Durand:
From STUPID to SOLID Code!
August 01, 2013 @ 12:45:11

William Durand has a new post to his site sharing not only the slides from his recent presentation on SOLID vs STUPID code but the same content written out. It provides a great overview of the two concepts and some examples of what to avoid. There's also a recording of the session you can listen to via the in-page player.

Last week I gave a talk about Object-Oriented Programming at Michelin, the company I am working for. I talked about writing better code, from STUPID to SOLID code! STUPID as well as SOLID are two acronyms, and have been covered quite a lot for a long time. However, these mnemonics are not always well-known, so it is worth spreading the word.

In the following, I will introduce both STUPID and SOLID principles. Keep in mind that these are principles, not laws. However, considering them as laws would be good for those who want to improve themselves.

He starts with the STUPID concepts first - Singleton, Tight Coupling, Untestability, Premature Optimization, Indescriptive Naming and Duplication. He goes through each of these and explains why they're bad things to have in your code. He then gets into the SOLID ideals - Single Responsibility Principle, Open/Closed Principle, Liskov Substitution Principle, Interface Segregation Principle and Dependency Inversion Principle. These are a bit more complex to understand but he does a good job (complete with code snippets) of each. The slides for his presentation are also included but they're just a high level look at the same concepts from the article.

0 comments voice your opinion now!
presentation solid stupid code concepts slides recording overview

Link: http://williamdurand.fr/2013/07/30/from-stupid-to-solid-code

blog comments powered by Disqus

Similar Posts

Jani Hartikainen's Blog: How to make your code testable

PHPClasses.org: Using DaDaBIK to create a PHP CRUD Database Front-End without coding

DevShed: Working with Multiple Template Files to Separate Logic from Presentation (Part 3)

Patrick Allaert's Blog: Coding standards: converts PHP4 style constructors to PHP5 one

Ilia Alshanetsky\'s Blog: php|tek Slides Posted


Community Events

Don't see your event here?
Let us know!


library interview podcast opinion api php7 release voicesoftheelephpant conference community configure framework performance part2 series laravel symfony2 introduction application example

All content copyright, 2015 PHPDeveloper.org :: info@phpdeveloper.org - Powered by the Solar PHP Framework