title: How do I structure a Timer in an external class in Swift?
body: <p>I am trying to create a new stopwatch timer.   </p>
  
  <p>I have my:</p>
  
  <ul>
  <li>Main Timer ViewController</li>
  <li>a timer Model - where I store my timer. </li>
  </ul>
  
  <p>When my timer finishes in my model how can I let the main ViewController know that it's been completed? 
  Ideally I would like to run a function the main UIViewController when the timer is completed in the model. </p>
  
  <pre><code>Class myTimer: NSObject {
      func stopTimer() {
          timer?.invalidate()
          print("timer Stopped at \(currentTime)")
      }
  }
  </code></pre>