• 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: [ANN] Cocoa Style for ObjC: 1 and 2
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [ANN] Cocoa Style for ObjC: 1 and 2


  • Subject: Re: [ANN] Cocoa Style for ObjC: 1 and 2
  • From: The Amazing Llama <email@hidden>
  • Date: Thu, 28 Oct 2004 08:15:26 -0700

On Oct 28, 2004, at 5:53 AM, Andreas Mayer wrote:
Am 27.10.2004 um 22:08 Uhr schrieb The Amazing Llama:

-infoForURL:
or
-infoWithURL:

although I'm still trying to decide which makes more sense, for or with.

I'm using 'objectForX:' when X is just used to look up object and 'objectWithX:' when X will be added to / included in object.

Alright, but what about when I'm storing a list of "Parks", and each has a name ivar. I create a dictionary parksByName, storing each park under its name key. I then want an accessor that gets a park by name. By your logic, either form is appropriate. I'm not saying you're wrong, here: I'm saying that you're too right.

Seth A. Roby The Amazing Llama < mail or AIM me at tallama at mac dot com>
"Life is like an exploded clown. It's really funny until you figure out what just happened."

_______________________________________________
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: 
 >[ANN] Cocoa Style for ObjC: 1 and 2 (From: Scott Stevenson <email@hidden>)
 >Re: [ANN] Cocoa Style for ObjC: 1 and 2 (From: The Amazing Llama <email@hidden>)
 >Re: [ANN] Cocoa Style for ObjC: 1 and 2 (From: Andreas Mayer <email@hidden>)

  • Prev by Date: NSRulerView subclassing is driving me nuts
  • Next by Date: Re: NSTableView with popupbuttons
  • Previous by thread: Re: [ANN] Cocoa Style for ObjC: 1 and 2
  • Next by thread: Re: [ANN] Cocoa Style for ObjC: 1 and 2
  • Index(es):
    • Date
    • Thread