title: How to fetch all images from custom Photo Album - Swift
body: <p>How to fetch <em>all images</em> from <em>custom</em> Photo Album? </p>
  
  <pre><code>var fetchOptions = PHFetchOptions()
  fetchOptions.sortDescriptors = [NSSortDescriptor(key:"creationDate", ascending: false)]
  fetchOptions.predicate = NSPredicate(format: "mediaType = %d", PHAssetMediaType.Image.rawValue)
  let allImages:PHFetchResult = PHAsset.fetchKeyAssetsInAssetCollection(albumList[index].collection, options: fetchOptions)
  </code></pre>
  
  <p>This code block is fetching just a few of them.
  Thanks.</p>
  
  <p>-> <code>albumList[index].collection</code> 's type is <code>PHAssetCollection</code></p>