FROM : Marco Scheurer
DATE : Thu Oct 28 17:33:43 2004
On Oct 27, 2004, at 10:57 PM, Scott Stevenson wrote:
>
> On Oct 27, 2004, at 1:08 PM, The Amazing Llama wrote:
>
>> 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,
>
> Yeah, this is a good one.
Yes, I use it too.
>> -infoForURL:
>> or
>> -infoWithURL:
>>
>> although I'm still trying to decide which makes more sense, for or
>> with.
IMHO for a dictionary query infoForURL makes more sense, similar to
objectForKey vs. objectWithKey. And it frees 'with' for the other
cases, mostly methods that construct an object with another.
Marco Scheurer
Sen:te, Lausanne, Switzerland http://www.sente.ch
DATE : Thu Oct 28 17:33:43 2004
On Oct 27, 2004, at 10:57 PM, Scott Stevenson wrote:
>
> On Oct 27, 2004, at 1:08 PM, The Amazing Llama wrote:
>
>> 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,
>
> Yeah, this is a good one.
Yes, I use it too.
>> -infoForURL:
>> or
>> -infoWithURL:
>>
>> although I'm still trying to decide which makes more sense, for or
>> with.
IMHO for a dictionary query infoForURL makes more sense, similar to
objectForKey vs. objectWithKey. And it frees 'with' for the other
cases, mostly methods that construct an object with another.
Marco Scheurer
Sen:te, Lausanne, Switzerland http://www.sente.ch






Cocoa mail archive

