title: @selector - With Multiple Arguments?
body: <p>I have been using <code>@selector</code> today for the first time and have not been able to work out how to do the following? How would you write the <code>@selector</code> if you had more than one argument?</p>
  
  <p>No arguments:</p>
  
  <pre><code>-(void)printText {
      NSLog(@"Fish");
  }
  
  [self performSelector:@selector(printText) withObject:nil afterDelay:0.25];
  </code></pre>
  
  <p>Single argument:</p>
  
  <pre><code>-(void)printText:(NSString *)myText {
      NSLog(@"Text = %@", myText);
  }
  
  [self performSelector:@selector(printText:) withObject:@"Cake" afterDelay:0.25];
  </code></pre>
  
  <p>Two arguments:</p>
  
  <pre><code>-(void)printText:(NSString *)myText andMore:(NSString *)extraText {
      NSLog(@"Text = %@ and %@", myText, extraText);
  }
  
  [self performSelector:@selector(printText:andMore:) withObject:@"Cake" withObject:@"Chips"];
  </code></pre>
  
  <p>Multiple Arguments: (i.e. more than 2)</p>
  
  <p><a href="https://developer.apple.com/documentation/foundation/nsinvocation" rel="nofollow noreferrer"><code>NSInvocation</code></a></p>