40,817 reputation
1399186
bio website
location London, United Kingdom
age
visits member for 3 years, 9 months
seen Oct 21 at 20:29

Aug
29
comment Why C# has no monkeypatching?
Funnily enough, one day later, I've just seen a situation where a List was being initialised in a subclass constructor but the object was being cast to a superclass before Adding to the List. That caused some confusion. :) Method hiding should be banned.
Aug
29
comment Design documents as part of Agile
@Paul: It is a good idea to have VERY high-level architecture diagrams, along with very light-weight coding standards, for new-comers. I've found that a good way to keep those documents up-to-date is to keep them in a wiki and get each newcomer to update where they find it is dated. But this question was about up-front design documents specifically.
Aug
29
answered Design documents as part of Agile
Aug
28
comment Why is Clean Code suggesting avoiding protected variables?
If you need protected variables OFTEN, then you're not prefering composition over inheritance, which is a whole other problem. If you need them occasionally then that's fine; he only says "avoid," not "never use."
Aug
28
answered Should I store log files in version control
Aug
28
comment Why don't languages use explicit fall-through on switch statements?
Yeah, sorry, I missed that there were two parts to your question. Unfortunately, phrased as it is, I'm voting to close because it's very close to a poll question. There will be lots of right answers.
Aug
28
comment Why don't languages use explicit fall-through on switch statements?
C# requires that you be explicit with goto case, so the premise of your question is a bit wrong.
Aug
28
comment Why C# has no monkeypatching?
You think that monkey-patching leads to misunderstandings but method hiding doesn't?
Aug
28
revised What's a good model for continuous manager <-> programmer feedback?
added 486 characters in body
Aug
28
answered What's a good model for continuous manager <-> programmer feedback?
Aug
27
revised Who should initialize dependencies in a TDD application?
added 83 characters in body
Aug
27
answered Who should initialize dependencies in a TDD application?
Aug
27
comment Object Oriented Programming: getters/setters or logical names
@gbjbaanb: Yes, but why would setting italic clear the bold? Then it wouldn't be a proper decorator pattern.
Aug
26
comment Object Oriented Programming: getters/setters or logical names
@gbjbaanb: Err. That's just not true. In fact it's the exact opposite of true. The entire point of the decorator is to be able to apply none, one or many and the calling code doesn't need to know at rendering time.
Aug
25
comment Object Oriented Programming: getters/setters or logical names
@BarryBrown: It doesn't imply sequence, necessarily, but you can certainly take sequence into account, where it's useful to.
Aug
25
awarded  Nice Answer
Aug
25
comment Object Oriented Programming: getters/setters or logical names
@Frog: Yeah, knowing that would have made a difference. If I were you, I'd raise another question and be a lot more specific about what you're trying to do. I tend to treat data objects as a slightly unique case (where getters and setters are more acceptable because I'm not trying to encapsulate logic as such) and I'll be interested to see the responses.
Aug
25
comment Object Oriented Programming: getters/setters or logical names
@stijn: Not really. There are a number of ways of avoiding that situation. For example, you can wrap that in a builder with a toggleStyle method (enum argument) which adds and removes decorators from an array, only decorating the final item when you call BuildDecoratedTextWriter. Or you can do as rwong suggested and complicate the base class. Depends on the circumstance and the OP wasn't specific enough about the overall spec to guess as to which is best for him. He seems smart enough to be able to figure it out once he gets the pattern though.
Aug
24
revised Object Oriented Programming: getters/setters or logical names
added 1 characters in body
Aug
24
revised Object Oriented Programming: getters/setters or logical names
added 1048 characters in body