Re: [ANN] Cocoa Style for ObjC: 1 and 2
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: Wed, 27 Oct 2004 13:08:27 -0700
On Oct 26, 2004, at 4:25 PM, Scott Stevenson wrote:
I've just posted a two-part tutorial on style conventions for Cocoa
using Objective-C:
http://cocoadevcentral.com/articles/000082.php
http://cocoadevcentral.com/articles/000083.php
Something that I've started to do, to make life simpler, is to start
naming dictionaries in the format
returnType + By + keyType
for instance,
infoByURL (a dictionary of URL objects pointing to "info" objects)
pagesByDate (a dictionary of date objects pointing to "page" arrays
(because of the plural))
etc. This makes it very easy to use later on, when you might have
multiple dictionaries pointing to the same data via different keys. It
is also relatively easy to expand this to accessors,
-infoForURL:
or
-infoWithURL:
although I'm still trying to decide which makes more sense, for or with.
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