2 ms·
Curiously, I almost never think of my code as "Is this a has-a or an is-a? Do I need a Factory pattern here?" I reach for the pattern names only when I need t
by nostrademons 17y ago
Curiously, I almost never think of my code as "Is this a has-a or an is-a? Do I need a Factory pattern here?" I reach for the pattern names only when I need to explain things to coworkers. I do occasionally think in terms of "what classes do I need to represent this problem?", but more accurately it's "Okay, what interface do I want to present to the outside world, what data do I have available to me, and how can I transform that data so it does what the interface claims it does?"