title: iOS - keyboardWillShow: unrecognized selector sent to instance
body: <pre><code>In my application I am adding following observer in init method of class A.
  
  
   [[NSNotificationCenter defaultCenter] addObserver:self
                                               selector:@selector(keyboardWillShow:)
                                                   name:UIKeyboardWillShowNotification
                                                 object:nil];
   [[NSNotificationCenter defaultCenter] addObserver:self
                                               selector:@selector(keyboardWillHide:)
                                                   name:UIKeyboardWillHideNotification
                                                 object:nil];
  </code></pre>
  
  <p>Then I am extending a class B from class A. keyboardWillShow and keyboardWillHide methods are written in super class i.e. class A. However application throws following exception when I click on some textview to enter text.</p>
  
  <pre><code>terminating app due to uncaught exception 'NSInvalidArgumentException',
  reason: '-[B   keyboardWillShow:]: unrecognized selector sent to instance xyz'
  </code></pre>
  
  <p>It is confuses as methods are already written in the supper class of B. If it is due to invalid arguments, then how can it be as arguments are passing by iOS itself.</p>