Welcome to MSDN Blogs Sign in | Join | Help

Browse by Tags

All Tags » Programming   (RSS)

Design Principle: Don't Repeat Yourself

There's a design principle I neglected to mention in my initial list but which certainly merits attention. That principle is this: whenever possible, don't repeat yourself (DRY). Put another way, do things one time, in one place rather than having the
Posted by SteveRowe | 3 Comments
Filed under:

Prefer Composition Over Inheritance

It's probably about time to bring my "Design Principles To Live By" series to a close. This is the last scheduled topic although I have one or two more I may post. Let's begin with some definitions: Composition - Functionality of an object is made up
Posted by SteveRowe | 2 Comments
Filed under:

Don't Blame the Compiler

It's been a busy week without much time to blog. In the mean time, here's a good reminder. It's Always Your Fault . Jeff Atwood explains why it's always the wrong idea to blame your tools. New programmers especially see something they don't understand
Posted by SteveRowe | 0 Comments
Filed under:

Which Language To Learn Next?

Once you have mastered one programming language, it is a good idea to branch out and learn some others. Each language is optimized for different things. Knowing multiple will give you a larger set of tools one of which which may solve the problem at hand
Posted by SteveRowe | 1 Comments
Filed under:

Classes Should Exhibit High Cohesion

This is part 4 of my ongoing Design Principles series. When designing the classes in your model, it is important that they each have a specific role to play. Cohesion means joining together to form a united whole. Classes and methods should be highly
Posted by SteveRowe | 1 Comments
Filed under:

Is There Value In Code Uniformity?

There seem to be two opposing views of coding standards. Some think that they should enforce uniformity in code. Everyone should use K&R braces, leave two lines between functions, and have a space after the if and before the opening parenthesis. Others
Posted by SteveRowe | 11 Comments
Filed under:

Arc Is Out

Over 6 years ago Paul Graham told the world that he was working on a new programming language called Arc. It would be some derivative of Lisp, but otherwise not much was known about it. Graham is the author of 2 books on Lisp and a popular series of essays
Posted by SteveRowe | 0 Comments
Filed under:

Design to Interfaces

This is the 2nd article in the Design Principles to Live By series. An interface is--for the purposes of this post at least--an abstract definition of the functionality of an object. It is the signature of a class divorced from its implementation. Think
Posted by SteveRowe | 7 Comments
Filed under:

Prefer Loose Coupling

This is the 3rd post in the Design Principles to Live By series. Coupling is the degree to which software components depend on each other. Tight coupling is a high degree of dependence. In practical terms, it means one component needs intimate knowledge
Posted by SteveRowe | 3 Comments
Filed under:

Encapsulate What Varies

It took a lot longer than I expected but this is first installment of my Design Principles To Live By series:  Encapsulate Variation.  This is a quick tour through the principles behind the design patterns.  Following these allows will
Posted by SteveRowe | 2 Comments
Filed under:

Design Principles To Live By

Object-oriented design and design patterns can seem complex. There are a lot of ideas and cases to consider. However, there are a handful of principles that, if followed, will result in code that complies with most if not all of the patterns. These are
Posted by SteveRowe | 0 Comments
Filed under:

The Need for a Real Build Process

Jeff Atwood at Coding Horror has a good post about how " F5 is not a build process ." In it, he explains how you need a real centralized build process. F5 (the "build and debug" shortcut key in Visual Studio) on a developer's machine is not a built process.
Posted by SteveRowe | 0 Comments

Don't Blame the User for Misusing Your API

A conversation the other day got me thinking about interfaces. As the author of an interface, it is easy to blame the users for its misuse. I think that's the wrong place for the blame. An interface that is used incorrectly is often poorly written. A
Posted by SteveRowe | 4 Comments
Filed under:

A Little Design Advice

A recent article on InfoWorld lays out "The eight secrets that make Apple No. 1." There are many things in the article that I disagree with but there are two that stick out as good advice for software design. The first "secret" is that engineering supports
Posted by SteveRowe | 1 Comments
Filed under:

Why Algorithms Matter

New programmers often don't appreciate the power of algorithms. They have one criteria for a piece of code: does it calculate the right answer? If it does, they go with it. Every CS program has at least one class on algorithms. However, if you are a self-taught
Posted by SteveRowe | 3 Comments
More Posts Next page »
 
Page view tracker