Re: NSDictionary question
Re: NSDictionary question
- Subject: Re: NSDictionary question
- From: Ondra Cada <email@hidden>
- Date: Sat, 16 Nov 2002 11:28:27 +0100
On Friday, November 15, 2002, at 12:45 , Andreas Mayer wrote:
AFAIK everything returns references, unless the documentation explicitely
says otherwise.
Nope. You don't know and don't need to know, unless (a) the documentation
explicitly says otherwise, or (b) it is self-evident (which case should be
documented too, just to be sure, but I can see why often it is not).
In most cases it would be quite useless to *not* get the original object
back.
I would argue those "most cases". Almost any -title is copied, and for a
good reason. With -identifier's it might be a copy or a reference
depending on usage: you should use them such a way it does not matter.
Cell values are generally copied, too. Even those dictionary keys are
copied (agreed, that's explicitly documented).
OTOH, of course, any delegate or data source would be referenced, even if
not documented so -- that's the self-evident case ;)
---
Ondra Cada
OCSoftware: email@hidden
http://www.ocs.cz
private email@hidden
http://www.ocs.cz/oc
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.