title: Objective-C: Forward most messages to another object (at runtime)
body: <h2>Subclass of <code>UIView</code></h2>
  <p>I have a subclass <code>MyView</code> of <code>UIView</code>.</p>
  <p>This subclass has a <code>@property UIView * realView</code>.</p>
  <h2>What I want to do</h2>
  <p>Whenever a message is sent to <code>MyView</code>, I want to &quot;forward it&quot; to <code>self.realView</code>, excepted for few messages.</p>
  <p>For instance, in the implementation of <code>MyView</code>, I would have this override:</p>
  <pre><code>- (void)setBackgroundColor:(UIColor *)color
  {
       [self.realView setBackgroundColor:color] ;
  }
  </code></pre>
  <p><strong>Instead of overriding explicitly all the methods, can I do it automatically, at the runtime?</strong></p>
  <h2>Exceptions</h2>
  <p>For some methods, I want to have an explicit control. For instance:</p>
  <pre><code>- (void)setFrame:(CGRect)frame
  {
      /* do stuff */
      
      [super setFrame:frame] ;
  }
  </code></pre>