May 6, 2006

...Learn TDD with Codemanship

Updated OO Design Principles Presentation

I finally got around to correcting some schoolboy errors and adding more slides to the Object Oriented Design Principles & Metrics presentation.

Error #1: My explanation of the Acyclic Dependencies Principle was rubbish, and I forgot to put in a metric for it. I hope the new version will make more sense and be of more practical use.

Error #2: The package cohesion metrics were just plain wrong. If a class C in package P is dependent on N other classes in P, and P contains M classes in total, then cohesion with respect to C is N/(M-1) not M/N, because I don't care if C is dependent on itself.

Addition #1: Class Cohesion - putting the behaviour as close to the data as possible. A fundamental principle that even some very experienced OO designers don't get. I've explained Brian Henderson-Sellers Lack of Cohesion of Methods metric, but the example points to a flaw in LCOM. See if you can spot it.

Addition #2: I'm a man on a mission when it comes to educating people about the importance of design expertise for anybody who writes code - not just designers and architects. The Cat Poetry images have found their way into the PPT, along with a "hazelnut in every bite" slide about how every line of code contains at least one significant design decision (well, almost).

This new - and hopefully improved - version will be used in the upcoming Object Oriented Design Masterclass in June & July in London, England.

Along with this, the workshop will include a session on evolutionary design (TDD) and refactoring, as well as metrics-driven software maintenance. I believe very strongly that it takes more design expertise to improve existing code than to design new code, and I have certainly learned more from doing that than I ever did writing software from scratch.
Posted 14 years, 8 months ago on May 6, 2006