From: Lyndon Samson Date: 2006-01-10T14:37:16+09:00 Subject: Re: global variables are bad?? ------=_Part_16230_25123566.1136871423167 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline On 1/10/06, Steve Litt wrote: > > On Monday 09 January 2006 10:15 pm, Lyndon Samson wrote: > > > I guess what I was thinking was, conceivably you could have a class wit= h > > say 100s of methods, all with full access to any ( > private/protected/public > > ) instance variables. How is that different to 100s of functions > accessing > > global variables? > > Why would you do that? With hundreds of methods, wouldn't these hundreds > of > methods tend to categorize in ways that you could split the big class int= o > smaller ones? Playing Devils Advocate for the sake of the discussion, a quote from MF :-) http://www.martinfowler.com/bliki/DuckInterface.html "Another factor is what the language encourages for implementing these structures. As Charles Millersaid "Java's design *affords* small interfaces, and utility functions provided as static method= s on helper classes. Ruby's design affords larger classes with mixed-in utility methods." SteveT > > Steve Litt > http://www.troubleshooters.com > slitt@troubleshooters.com > > -- Into RFID? www.rfidnewsupdate.com Simple, fast, news. ------=_Part_16230_25123566.1136871423167--