Skip to content

Instantly share code, notes, and snippets.

View michaelosity's full-sized avatar

Michael Wells michaelosity

View GitHub Profile
@JadenGeller
JadenGeller / ClockController.swift
Last active September 2, 2016 17:12
Clock Controller
import Foundation
// Controller that evokes its callback every minute
class ClockController {
private let minuteCallback: NSDate -> ()
init(minuteCallback: NSDate -> ()) {
self.minuteCallback = minuteCallback
callbackAndReschedule()
}