Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.java.programmer > #2610
| Path | csiph.com!x330-a1.tempe.blueboxinc.net!newsfeed.hal-mli.net!feeder1.hal-mli.net!nx01.iad01.newshosting.com!newshosting.com!69.16.185.16.MISMATCH!npeer02.iad.highwinds-media.com!news.highwinds-media.com!feed-me.highwinds-media.com!post01.iad.highwinds-media.com!newsfe17.iad.POSTED!00000000!not-for-mail |
|---|---|
| From | David Lamb <dalamb@cs.queensu.ca> |
| User-Agent | Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.2.15) Gecko/20110303 Thunderbird/3.1.9 |
| MIME-Version | 1.0 |
| Newsgroups | comp.lang.java.programmer |
| Subject | Re: Refactoring discovery |
| References | <kbgoo6dfrkh58r3ogel9nb6rekrs258it2@4ax.com> <imigoe$bpa$1@dont-email.me> <atrqo6hgt63ro0nsuhdrlm9kncv3pb7lra@4ax.com> |
| In-Reply-To | <atrqo6hgt63ro0nsuhdrlm9kncv3pb7lra@4ax.com> |
| Content-Type | text/plain; charset=ISO-8859-1; format=flowed |
| Content-Transfer-Encoding | 7bit |
| Lines | 25 |
| Message-ID | <PgMkp.1470$0s5.1069@newsfe17.iad> (permalink) |
| NNTP-Posting-Host | 67.193.237.254 |
| X-Complaints-To | abuse@cogeco.net |
| X-Trace | newsfe17.iad 1301516463 67.193.237.254 (Wed, 30 Mar 2011 20:21:03 UTC) |
| NNTP-Posting-Date | Wed, 30 Mar 2011 20:21:03 UTC |
| Date | Wed, 30 Mar 2011 16:21:01 -0400 |
| Xref | x330-a1.tempe.blueboxinc.net comp.lang.java.programmer:2610 |
Show key headers only | View raw
On 26/03/2011 12:50 AM, Roedy Green wrote:
> On Fri, 25 Mar 2011 09:43:56 -0700, markspace<-@.> wrote, quoted or
> indirectly quoted someone who said :
>
>> I think it would elucidate your refactoring pattern more if you included
>> an example. What you did post is very general:
>
> You can see the new code at
> http://mindprod.com/applet/canadiantax.html
>
> The class in question is CalculateCanadianTaxes
>
> The outputs include GST, HST, PST tax rates, GST, HST, PST tax
> amounts, total tax, and total payable.
GHAH. Conceptually that's really
CalculateCanadianTaxes: farTooManyInputs -> farTooManyOutputs
Single, vastly complex input; single, vastly complex output. I'm
serious; I can't see how anyone can think of the results of a tax
computation as anything other than one big record type.
Much nicer is the Ohio state tax form from around 1975:
OhioTax = federalTax * factorLessThanOne
But that's a whole other issue.
Back to comp.lang.java.programmer | Previous | Next | Find similar
Re: Refactoring discovery David Lamb <dalamb@cs.queensu.ca> - 2011-03-30 16:21 -0400
csiph-web