     
     // MARK: NSFetchedResultsControllerDelegate
     
+    /**
+        Notifies the receiver that the fetched results controller is about to start processing of one or more changes due to an add, remove, move, or update.
+    
+        :param: controller The fetched results controller that sent the message.
+    */
     public func controllerWillChangeContent(controller: NSFetchedResultsController) {
         if !suspendAutomaticTrackingOfChangesInManagedObjectContext {
             tableView.beginUpdates()

        }
    }

    public func controllerDidChangeContent(controller: NSFetchedResultsController) {
        if !suspendAutomaticTrackingOfChangesInManagedObjectContext {
            // do batch updates on collection view

    
    // MARK: UICollectionViewDataSource
    
    /**
        Asks the data source for the number of sections in the collection view.
    
        :param: collectionView An object representing the collection view requesting this information.
    
        :returns: The number of sections in collectionView.
    */
    override public func numberOfSectionsInCollectionView(collectionView: UICollectionView) -> Int {
        return fetchedResultsController?.sections?.count ?? 0
    }
    
    /**
        Asks the data source for the number of items in the specified section. (required)
    
        :param: collectionView An object representing the collection view requesting this information.
        :param: section An index number identifying a section in collectionView.
    
        :returns: The number of rows in section.
    */
    override public func collectionView(collectionView: UICollectionView, numberOfItemsInSection section: Int) -> Int {
        return (fetchedResultsController?.sections?[section] as? NSFetchedResultsSectionInfo)?.numberOfObjects ?? 0
    }
