Re: Is selector in protocol?
Re: Is selector in protocol?
- Subject: Re: Is selector in protocol?
- From: email@hidden
- Date: Wed, 24 Oct 2001 22:59:20 +0200
On Wednesday, October 24, 2001, at 10:15 PM, Paul Mix wrote:
Is there a way to tell if a particular selector is declared in a formal
protocol? I'd like to use forward-invocation on an object, determining
which object to forward to based on which protocol the
forwarded-selector is declared in.
Look at "/usr/include/Protocol.h".
How about
if([@protocol(someProtocol) descriptionForInstanceMethod:theSelector])
{
...
}
You may also want to look at NSProtocolChecker.
Regards,
John Hornkvist
--
ToastedMarshmallow, the perfect Cocoa companion
http://www.toastedmarshmallow.com