Tag Archives: YAGNI

Brainless Getters & Setters are a Waste

Someone long ago set a pattern that all members should have a getter and setter method.  Some are persuaded that this is OO and this is encapsulation, so a lot of inexperienced programmers do this by default.  But this is a problem. Read the rest of this entry »

Leave a comment

Posted by on March 7, 2016 in Coding, Example Code, practice


Tags: , , , ,

#26 Don’t add Methods and Classes that you don’t need.

This should be obvious, but it is a rule that is violated quite often. This is one corollary to the YAGNI (You Aren’t Gonna Need It) Principle.    This post discusses that there is a proper time to do things, and it is a waste to do them ahead of time. Read the rest of this entry »

Leave a comment

Posted by on April 2, 2012 in Coding, Design


Tags: ,