Re: NSStringFromClass versus className ?
Re: NSStringFromClass versus className ?
- Subject: Re: NSStringFromClass versus className ?
- From: "Kyle Sluder" <email@hidden>
- Date: Wed, 20 Feb 2008 18:37:28 -0500
On Wed, Feb 20, 2008 at 1:23 PM, Mike Abdullah
<email@hidden> wrote:
> With this I suspect that NSStringFromClass() will return the dynamic
> class name which will be different to what your code might expect. -
> className I believe will still return your object's intended class.
Regardless of whether or not this is the case, keep in mind that you
should always be testing for object class using the NSObject protocol
methods -isKindOfClass: (allows for inheritance) and -isMemberOfClass:
(strict test).
--Kyle Sluder
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden