This blog contains reflections and thoughts on my work as a software engineer

søndag den 28. december 2008

Buy it - just buy it.

The best thing about Christmas is the days off from work. You get to spend a lot of time with your family and that's great. You also get to see a lot of movies in the TV - which is nice because I like to see a good movie. I don't see a lot of TV basicly because I choose otherwise - my life probably goes on even though I don't know who got voted off the island during the last episode of Survivor / American Idol / Big Brother / (insert any mediocre TV-show here)...

You also get to read a lot so I've finished the book I blogged about three days ago - Michael Feathers Working effectively with legacy code. The short story is: Buy it - I was completely sold on his final appendix where he goes through all the various ways of decoupling dependencies - each example is followed by a codeexample and each example and explanation covers about two to four pages. Extremely nice setup and well thought.

One of his examples is the "Extend and subclass" refactoring. I never thought of that one but it is so obvious and offers lots of advantages with only a few minor disadvanteges so I'll share it with you here:

...(and 15 minutes passed...)

No excuses: I have failed to come up with a decent coding example on my own - the code just turned against me once I looked at the time and found out that one of the three "Lord of the Rings" are beginning in 5 minutes... Not that I haven't seen all of them at least 3-4 times but this is Christmas and about the first vacation this year which doesn't include a lot of work on our house or trips to far-far-away family - so watching a movie I've seen before and NOT get up from the couch and get some work done is really a new sensational feeling..... I could probably learn something by doing a bit of coding on the issue I'll just find a perfectly good example written by Jimmy Bogard for you  :o)

I'm off to see some orc bashing. Happy New Year to all of you - see you in 2009  :o)

Regards K.

Ingen kommentarer: