Objective-Cでメソッド(メッセージ)の型を調べることは可能だろうか、またどのようにして実装すれば良いのだろうか。 いろいろ調べてみたが、自身が持つメソッド"fooBar:"の引数の個数と型を調べるコードは以下のようになるようだ。 SEL selector = @selector(fooBar:); NSMethodSignature *methodSignature = [[self class] instanceMethodSignatureForSelector: selector]; if ( methodSignature ) { NSInvocation *invocation = [NSInvocation invocationWithMethodSignature: methodSignature]; int i; numberOfArguments = [[inv