title: iOS - How to check if an NSOperation is in an NSOperationQueue?
body: <p>From the docs:</p>
  
  <blockquote>
    <blockquote>
      <p>An operation object can be in at most one operation queue at a time and this method throws an NSInvalidArgumentException exception if the operation is already in another queue. Similarly, this method throws an NSInvalidArgumentException exception if the operation is currently executing or has already finished executing.</p>
    </blockquote>
  </blockquote>
  
  <p>So how do I check if I can safely add an NSOperation into a queue?</p>
  
  <p>The only way I know is add the operation and then try to catch the exception if the operation is already in a queue or executed before.</p>