class PyInvokeAppDelegate(NSObject): def awakeFromNib(self): self.myReceiver = MyReceiver.alloc().init() self.go_(self) def go_(self,sender): NSLog("go_ %s" % sender.description()) flag = self.myReceiver.respondsToSelector_( "absentMethod:") NSLog("go_ returning %s" % flag) class MyReceiver(NSObject): def respondsToSelector_(self, s): NSLog("Receiver respondsToSelector_ %s" % s) super(MyReceiver,self).respondsToSelector_(s)
|