• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: A Challenge WAS Accessor method idioms...
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: A Challenge WAS Accessor method idioms...


  • Subject: Re: A Challenge WAS Accessor method idioms...
  • From: John Brownlow <email@hidden>
  • Date: Thu, 24 Mar 2005 14:37:29 -0500

On Mar 24, 2005, at 2:18 PM, Jonathon Mah wrote:

if (index < thingsCount) return;

Of course, should be >.

heh, that was fast... I have some more code that needs debugging here if you're interested...



I haven't looked into it, but how messy would it be to have a small list of method names that you'd use to forward invocations on to the array? You'd then have a reasonably compact and non-reduntant way of doing this.

I just think in many cases it's solving a non-existent problem. There are two approaches here... write a whole chunk of bulletproof code in case you ever decide to change something, and take the cost up front, or write a much smaller chunk of lighter, more transparent, and more legible code and take a hit if you subsequently decide to change from an array to a tree.


I'm personally in favor of the more agile approach when circumstances permit but YMMV.

--
John Brownlow
Deep Fried Films, Inc

http://www.johnbrownlow.com
http://www.pinkheadedbug.com

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >Accessor method idioms... (From: Mike Ferris <email@hidden>)
 >Re: Accessor method idioms... (From: John Brownlow <email@hidden>)
 >Re: Accessor method idioms... (From: "M. Uli Kusterer" <email@hidden>)
 >A Challenge WAS Accessor method idioms... (From: John Brownlow <email@hidden>)
 >Re: A Challenge WAS Accessor method idioms... (From: Jonathon Mah <email@hidden>)

  • Prev by Date: Re: Sliding views around
  • Next by Date: Re: Redirect NSLog()
  • Previous by thread: Re: A Challenge WAS Accessor method idioms...
  • Next by thread: Re: A Challenge WAS Accessor method idioms...
  • Index(es):
    • Date
    • Thread