Just A Summary : Today's Noun is: Reticence http://www.bofh.org.uk/articles/2007/09/27/todays-noun-is-reticence.rss en-us 40 Piers Cawley Practices Punditry Comment on Today's Noun is: Reticence by Ramon Leon <p>In fact, hardly ever, if at all! Options are better done by cascades, but I guess in lesser languages, that&#8217;s not an option.</p> Thu, 27 Sep 2007 20:40:35 -0500 urn:uuid:0700eba2-1bc9-41c6-ae4a-d5b457ef3689 http://www.bofh.org.uk/articles/2007/09/27/todays-noun-is-reticence#comment-727 Comment on Today's Noun is: Reticence by Pat Maddox <p>One of my favorite strategies when BDDing is to introduce a new object whenever I get stuck and am not sure how to proceed. Sometimes I&#8217;ll be working on a method and it&#8217;s just not obvious to me how to implement a part of it. At that point I create a mock with some reasonable method name and stub it to return whatever result I need. Then I can create a new class that implements the behavior I need.</p> <p>When I first did this it felt pretty unnatural. One way it differed in particular from a more traditional mock approach is that I didn&#8217;t really discover the interface of this new object &#8211; in fact it almost always ends up different from the original stubbed method call. On the flip side when I ask what to do when an object doesn&#8217;t know how to do something it needs to, the answer is have it ask someone else who does know, and in <span class="caps">OOP</span> someone else who does know = another object.</p> <p>I totally agree with considering whether a parameter object would be better than an options hash. Options hashes are fine when you&#8217;re just passing some parameters around, but if you&#8217;re doing conditionals, or parsing data, you&#8217;re into the realm of behavior and it&#8217;s probably a good idea to encapsulate it.</p> <p>Nice post.</p> Fri, 28 Sep 2007 02:02:04 -0500 urn:uuid:404a3bf4-527e-4647-a9c5-706b124f9975 http://www.bofh.org.uk/articles/2007/09/27/todays-noun-is-reticence#comment-728