Re: run-time list of selectors in protocol?
Re: run-time list of selectors in protocol?
- Subject: Re: run-time list of selectors in protocol?
- From: Jeff LaMarche <email@hidden>
- Date: Fri, 9 Dec 2005 11:54:51 -0500
On Dec 9, 2005, at 11:51 AM, William Turner wrote:
Is there a way I can query a protocol at run-time to get a list of
the selectors it includes?
On a related note, is there a way to get more detailed information
when a class fails to "conformToProtocol"?
I'm having trouble envisioning a situation where you would need to
know at runtime what methods a protocol contains. This seems like
it's going to be primarily a compile-time issue.
You can always look at the protocol's header files, which you'll find
inside the framework that contains it. Although compiled frameworks
do not have the source code, they do have the header files, which
should list all the required methods. If it's an Apple-supplied
protocol, you can also just use XCode's documentation browser or
AppKiDo to find out how to conform to the protocol.
_______________________________________________
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