[Tutor] recommendation for good OO book?
kent37 at tds.net
Sat Mar 10 15:55:04 CET 2007
Alan Gauld wrote:
> 5) Agile Software Development by Martin
> (I;'m in two minds about recommending this since it varies between
> brilliant and poor)
> Pros: The OOP bits are good but Martin is obsessed by interfaces
> and is very C++/Java focussed.
> Cons: There is a lot of stuff about Agile development which frankly
> is not good. It has lots of bad ideas, mistakes and dubious code.
> It's not bad for small scale programming but the Agile stuff is very
> poor compared to the OO stuff IMHO. But if you can borrow a copy,
> read up the OO bits and scan the rest its quite good.
Hmm...once again I think we will have to agree to disagree :-) This is
one of my all-time favorite software development books and IMO one of
the few that shows *why* to use OOP and *how* to do it from a practical
point of view. So many OOP books start with "Identify the nouns in your
domain. These may correspond to objects in the implementation." Yes,
but...that is just a starting point. Martin shows how using real
requirements to drive object-oriented design can lead to an architecture
that is loosely coupled, cohesive and maintainable.
My experience with agile development in the style of this book is that
it works fantastically well for small- to medium-sized projects. The
writing of Robert Martin has been a huge influence in my professional
I don't have experience with huge projects like Alan works on, so I
can't say if this style works there. This difference in background
probably accounts for our differing opinions.
I would say Martin is obsessed by loose coupling and uses interfaces as
a means to this end. But he is good about designing to meet real
requirements rather than designing to meet some abstract goal (the way
much of the Java libraries seem to have been written).
Martin likes to use metrics to evaluate code. I have not found any value
in this. The rest of his ideas I find very useful.
The book is very Java and C++ focused; Python has a looser style. I read
this book before I had written a lot of Python so I don't know how well
it applies there. This is what kept me from recommending it in response
to the OP. But in 2003 what language would you have used for a book on
OOP? I remember being thrilled that he used mostly Java vs C++.
Several chapters from this book are available on-line as stand-alone
essays. Go to
and click on Robert C. Martin. Scroll down past the "Craftsman" series.
"Agile Process" is basically chapter 1 of the book.
The Bowling Game: An example of test-first pair programming
Inheritance vs. Delegation
Singleton And Monostate
Proxy and Stairway to Heaven
are all book chapters or early versions of chapters, and some of the
"principles" appear in the book also.
More information about the Tutor