This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Regex Collection | |
Norwegian Address Format | |
/([^,]+),\s*(\d{4})\s*([^,]+)(?:,\s*([^,]+))?/u | |
Street Name xx, zip City, Country | |
// PHP usage | |
preg_match("/([^,]+),\\s*(\\d{4})\\s*([^,]+)(?:,\\s*([^,]+))?/u", $location, $matches); | |
if ($matches) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// MARK: NSFetchedResultsControllerDelegate | |
func controllerWillChangeContent(controller: NSFetchedResultsController) { | |
self.tableView.beginUpdates() | |
} | |
func controller(controller: NSFetchedResultsController, | |
didChangeObject anObject: AnyObject, | |
atIndexPath indexPath: NSIndexPath?, | |
forChangeType type: NSFetchedResultsChangeType, |