Series

Code Smells

In this series, we will see several symptoms and situations that make us doubt the quality of our developments. We will present possible solutions. Most are just clues. They are no hard rules.

Articles in this series

Code Smell 01 - Anemic Models

Oct 20, 20202 min read 1.1K views

TL;DR: Don't use objects as data structures Protocol is empty (with setters/getters). If we ask a domain expert to describe an entity he/she would hardly tell it is 'a bunch of attributes'. Problems No Encapsulation. No mapping to real world entit...

Code Smell 01 - Anemic Models
Code Smell 02 - Constants and Magic Numbers
Code Smell 03 - Functions Are Too Long
Code Smell 04 - String Abusers
Code Smell 05 - Comment Abusers
Code Smell 06 - Too Clever Programmer