<?xml version="1.0" encoding="UTF-8"?><!-- generator="wordpress/2.2.1" -->
<rss version="2.0" 
	xmlns:content="http://purl.org/rss/1.0/modules/content/">
<channel>
	<title>Comments on: DRAFT - A Design Compass: East Oriented &#8230;</title>
	<link>http://jamesladdcode.com/2007/02/02/draft-a-design-compass-east-oriented/</link>
	<description>code koans and other food for thought ...</description>
	<pubDate>Fri, 18 May 2012 09:45:32 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.2.1</generator>

	<item>
		<title>By: I give the orders around here! &#171; crustyoldev</title>
		<link>http://jamesladdcode.com/2007/02/02/draft-a-design-compass-east-oriented/#comment-486</link>
		<author>I give the orders around here! &#171; crustyoldev</author>
		<pubDate>Sun, 06 May 2012 12:08:53 +0000</pubDate>
		<guid>http://jamesladdcode.com/2007/02/02/draft-a-design-compass-east-oriented/#comment-486</guid>
		<description>[...] friend of mine is a strong advocate of this and has come up with the East Oriented approach that explains this principle [...]</description>
		<content:encoded><![CDATA[<p>[&#8230;] friend of mine is a strong advocate of this and has come up with the East Oriented approach that explains this principle [&#8230;]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Car Respray</title>
		<link>http://jamesladdcode.com/2007/02/02/draft-a-design-compass-east-oriented/#comment-451</link>
		<author>Car Respray</author>
		<pubDate>Fri, 04 Nov 2011 18:05:23 +0000</pubDate>
		<guid>http://jamesladdcode.com/2007/02/02/draft-a-design-compass-east-oriented/#comment-451</guid>
		<description>&lt;strong&gt;Car Respray...&lt;/strong&gt;

[...]jamesladdcode.com  &#187; Blog Archive   &#187; DRAFT - A Design Compass: East Oriented &#8230;[...]...</description>
		<content:encoded><![CDATA[<p><strong>Car Respray&#8230;</strong></p>
<p>[&#8230;]jamesladdcode.com  &raquo; Blog Archive   &raquo; DRAFT - A Design Compass: East Oriented &#8230;[&#8230;]&#8230;</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: jamesladdcode.com &#187; Blog Archive &#187; New On East &#8230;</title>
		<link>http://jamesladdcode.com/2007/02/02/draft-a-design-compass-east-oriented/#comment-408</link>
		<author>jamesladdcode.com &#187; Blog Archive &#187; New On East &#8230;</author>
		<pubDate>Fri, 10 Jul 2009 09:29:36 +0000</pubDate>
		<guid>http://jamesladdcode.com/2007/02/02/draft-a-design-compass-east-oriented/#comment-408</guid>
		<description>[...] there has been some interest in my East approach to software development both in the post here in my blog and in the Test Driven Design group on [...]</description>
		<content:encoded><![CDATA[<p>[&#8230;] there has been some interest in my East approach to software development both in the post here in my blog and in the Test Driven Design group on [&#8230;]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Strazhce</title>
		<link>http://jamesladdcode.com/2007/02/02/draft-a-design-compass-east-oriented/#comment-407</link>
		<author>Strazhce</author>
		<pubDate>Thu, 09 Jul 2009 14:21:14 +0000</pubDate>
		<guid>http://jamesladdcode.com/2007/02/02/draft-a-design-compass-east-oriented/#comment-407</guid>
		<description>Hi, James.

Your examples are nice and educating in what is possible. Your code definitively promotes reuse and DRY.

My concern is understandability/readability/overengineering. Examples 8 and 9 are easily readable. Example 10 and 11 are worse. In Ex 8 you needed 1 class, which did all things. In Ex 10 you need MovieAction, Selector, Finder(?) and in Ex 11 all those subclasses.
I'm struggling to find justification for that complexity. How about adding some rationale, when this design should and shouldn't be used.

Oleg</description>
		<content:encoded><![CDATA[<p>Hi, James.</p>
<p>Your examples are nice and educating in what is possible. Your code definitively promotes reuse and DRY.</p>
<p>My concern is understandability/readability/overengineering. Examples 8 and 9 are easily readable. Example 10 and 11 are worse. In Ex 8 you needed 1 class, which did all things. In Ex 10 you need MovieAction, Selector, Finder(?) and in Ex 11 all those subclasses.<br />
I&#8217;m struggling to find justification for that complexity. How about adding some rationale, when this design should and shouldn&#8217;t be used.</p>
<p>Oleg</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: mgsram</title>
		<link>http://jamesladdcode.com/2007/02/02/draft-a-design-compass-east-oriented/#comment-406</link>
		<author>mgsram</author>
		<pubDate>Mon, 06 Jul 2009 13:11:42 +0000</pubDate>
		<guid>http://jamesladdcode.com/2007/02/02/draft-a-design-compass-east-oriented/#comment-406</guid>
		<description>Hi James, 
Sorry if i caused any confusion although, I used them on choice. Here is a simplified version using notepad. I have also provided comments to explain the use of Limit and passing Account object. 

class CreditCalculator
{
  //The return could be a Limit Entity object that provides at the minimum
  //a useful toString implementation. It could also be used to control the
  //underlying storage type 

  public double calculateLimit(double balance)
  {
     //the calculation can be more complex here using multiple
     //members of the account.. for e.g. age of the account could be
     //a factor.. thats why I had an Account object before

     return balance *2; 
  }
}
.
.
//somewhere in my payment processing logic..
.
double creditLimit = creditCalculator.calculateLimit(myAccount.getBalance());
if(creditLimit </description>
		<content:encoded><![CDATA[<p>Hi James,<br />
Sorry if i caused any confusion although, I used them on choice. Here is a simplified version using notepad. I have also provided comments to explain the use of Limit and passing Account object. </p>
<p>class CreditCalculator<br />
{<br />
  //The return could be a Limit Entity object that provides at the minimum<br />
  //a useful toString implementation. It could also be used to control the<br />
  //underlying storage type </p>
<p>  public double calculateLimit(double balance)<br />
  {<br />
     //the calculation can be more complex here using multiple<br />
     //members of the account.. for e.g. age of the account could be<br />
     //a factor.. thats why I had an Account object before</p>
<p>     return balance *2;<br />
  }<br />
}<br />
.<br />
.<br />
//somewhere in my payment processing logic..<br />
.<br />
double creditLimit = creditCalculator.calculateLimit(myAccount.getBalance());<br />
if(creditLimit</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: james</title>
		<link>http://jamesladdcode.com/2007/02/02/draft-a-design-compass-east-oriented/#comment-405</link>
		<author>james</author>
		<pubDate>Mon, 06 Jul 2009 10:17:47 +0000</pubDate>
		<guid>http://jamesladdcode.com/2007/02/02/draft-a-design-compass-east-oriented/#comment-405</guid>
		<description>Hi Sriram,

Thank you for the comments and the example.

I would ask why do you need the Limit as this will shape how the East/Right approach applies ?

Why does calculateLimit() take an Account?

What if CreditCalculator took an initial value and some function to call when it had the calculated value ?  eg:  calculateLimitThenCall(100, thingToDo)
(Please excuse my naming which Im making verbose)</description>
		<content:encoded><![CDATA[<p>Hi Sriram,</p>
<p>Thank you for the comments and the example.</p>
<p>I would ask why do you need the Limit as this will shape how the East/Right approach applies ?</p>
<p>Why does calculateLimit() take an Account?</p>
<p>What if CreditCalculator took an initial value and some function to call when it had the calculated value ?  eg:  calculateLimitThenCall(100, thingToDo)<br />
(Please excuse my naming which Im making verbose)</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: mgsram</title>
		<link>http://jamesladdcode.com/2007/02/02/draft-a-design-compass-east-oriented/#comment-404</link>
		<author>mgsram</author>
		<pubDate>Mon, 06 Jul 2009 04:53:41 +0000</pubDate>
		<guid>http://jamesladdcode.com/2007/02/02/draft-a-design-compass-east-oriented/#comment-404</guid>
		<description>Hello James,
Can you please clarify on how this will work in the following scenario - 

Supposing there is another object that has the responsibility of assessing the credit limit for individuals based on the balance they have on their account? 

The conventional way of doing it for an example would be.

class CreditCalculator
{
   public Limit calculateLimit(Account acct)
   {
       return new Limit ( acct.getBalance() *2);
    }
}

Thanks
Sriram</description>
		<content:encoded><![CDATA[<p>Hello James,<br />
Can you please clarify on how this will work in the following scenario - </p>
<p>Supposing there is another object that has the responsibility of assessing the credit limit for individuals based on the balance they have on their account? </p>
<p>The conventional way of doing it for an example would be.</p>
<p>class CreditCalculator<br />
{<br />
   public Limit calculateLimit(Account acct)<br />
   {<br />
       return new Limit ( acct.getBalance() *2);<br />
    }<br />
}</p>
<p>Thanks<br />
Sriram</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: james</title>
		<link>http://jamesladdcode.com/2007/02/02/draft-a-design-compass-east-oriented/#comment-403</link>
		<author>james</author>
		<pubDate>Sun, 05 Jul 2009 00:51:42 +0000</pubDate>
		<guid>http://jamesladdcode.com/2007/02/02/draft-a-design-compass-east-oriented/#comment-403</guid>
		<description>&lt;p&gt;Al,&lt;/p&gt;
&lt;p&gt;Thank you for the comments.&lt;/p&gt;
&lt;p&gt;Dynamically typed languages do make an East approach easier, but I'm still surprised by how many people still don't go east when using them.&lt;/p&gt;
&lt;p&gt;With regard to ambiguity, I'm not sure I understand you point as East required all functions are 1.) void or 2.) return this/self.  I think the "ask" problem creeps in when it isn't one of these. Can we discuss further?&lt;/p&gt;
&lt;p&gt;Rgs, James.&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>Al,</p>
<p>Thank you for the comments.</p>
<p>Dynamically typed languages do make an East approach easier, but I&#8217;m still surprised by how many people still don&#8217;t go east when using them.</p>
<p>With regard to ambiguity, I&#8217;m not sure I understand you point as East required all functions are 1.) void or 2.) return this/self.  I think the &#8220;ask&#8221; problem creeps in when it isn&#8217;t one of these. Can we discuss further?</p>
<p>Rgs, James.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Al Chou</title>
		<link>http://jamesladdcode.com/2007/02/02/draft-a-design-compass-east-oriented/#comment-402</link>
		<author>Al Chou</author>
		<pubDate>Sat, 04 Jul 2009 16:03:34 +0000</pubDate>
		<guid>http://jamesladdcode.com/2007/02/02/draft-a-design-compass-east-oriented/#comment-402</guid>
		<description>It's interesting to see East / CPS as the way an explicitly-statically-typed language is used like a dynamically typed language -- except that some dynamically typed languages profit greatly from their "everything is an expression with a value" property, which declaring everything's type as void summarily precludes.

As for the text of this draft, I would like to see the East/West distinction be clarified a bit to say that the object they refer to is never the self/this object but rather anOtherObject (otherwise the "tell, don't ask" type of ambiguity creeps in).</description>
		<content:encoded><![CDATA[<p>It&#8217;s interesting to see East / CPS as the way an explicitly-statically-typed language is used like a dynamically typed language &#8212; except that some dynamically typed languages profit greatly from their &#8220;everything is an expression with a value&#8221; property, which declaring everything&#8217;s type as void summarily precludes.</p>
<p>As for the text of this draft, I would like to see the East/West distinction be clarified a bit to say that the object they refer to is never the self/this object but rather anOtherObject (otherwise the &#8220;tell, don&#8217;t ask&#8221; type of ambiguity creeps in).</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Bill Birch</title>
		<link>http://jamesladdcode.com/2007/02/02/draft-a-design-compass-east-oriented/#comment-13</link>
		<author>Bill Birch</author>
		<pubDate>Sat, 24 Feb 2007 12:02:00 +0000</pubDate>
		<guid>http://jamesladdcode.com/2007/02/02/draft-a-design-compass-east-oriented/#comment-13</guid>
		<description>CPS = Continuation Passing Style. CPS has been around for years. Ironically if you convert all your code to CPS you prove tat all function calls can be translated to GOTO instructions! So a language which supports tail call elimination executs CPS  (or East) with incredible efficiency.

http://en.wikipedia.org/wiki/Continuation_passing_style</description>
		<content:encoded><![CDATA[<p>CPS = Continuation Passing Style. CPS has been around for years. Ironically if you convert all your code to CPS you prove tat all function calls can be translated to GOTO instructions! So a language which supports tail call elimination executs CPS  (or East) with incredible efficiency.</p>
<p><a href="http://en.wikipedia.org/wiki/Continuation_passing_style" rel="nofollow">http://en.wikipedia.org/wiki/Continuation_passing_style</a></p>
]]></content:encoded>
	</item>
</channel>
</rss>

