title: Swift 3 - Making class iterable
body: <p>Consider my two classes:</p>
  
  <pre><code>// Person.swift
  class Person {
      var parents: Parents?
      // ...
  }
  
  // Parents.swift. Only a collection of parents with some helper methods.
  class Parents {
      var parents = [Person]()
      // ...
  }
  </code></pre>
  
  <p>How could I make <code>Parents</code> iterate in a for loop using the iterators of <code>parents</code>. This is not a real world app. I'm just curious. Just would like to use <code>for parent in myParents</code> instead of <code>for parent in myParents.parents</code>.</p>