Monthly Archives: March 2013

Coding Practice: Dependency Injection

Coding Practice: Why is using “new” a bad thing? The usage of “new” in a class can be an indicator of tight coupling, which can lead to code that is difficult to test and easily broken by change. Consider how … Continue reading

Posted in Software Architecture | Tagged , | Leave a comment

Coding Practice: Feature Envy

Coding   Practice: What is feature envy? A method in Class A seems way   too interested in the workings and data fields of Class B. The feature envy   from Class A to Class B is an indication of … Continue reading

Posted in Software Architecture | Tagged , , | Leave a comment

Coding Practice: Commenting Out Code

Coding Practice: When should I check in commented code? Code that is commented out should not be checked into TFS. Quote: “When you see commented-out code, delete it! Don’t worry; the source code control system still remembers it. If anyone really … Continue reading

Posted in Software Architecture | Tagged , | Leave a comment

Coding Practice: Commenting Code

Coding Practice: What is the appropriate amount of comments for my code? Comments are usually an indication that the intent of your method or class is not clear.  In general you should strive for no comments. Quote: “Comments are indicative … Continue reading

Posted in Software Architecture | Tagged , | Leave a comment