Skip to content

Instantly share code, notes, and snippets.

@speaktoalvin
Last active November 17, 2016 06:30
Show Gist options
  • Save speaktoalvin/5e6b4b3c7733566a472cf128f51bb9ec to your computer and use it in GitHub Desktop.
Save speaktoalvin/5e6b4b3c7733566a472cf128f51bb9ec to your computer and use it in GitHub Desktop.
TodoSwift3
import Foundation
import CoreData
@objc(Todos)
public class Todos: NSManagedObject {
}
import Foundation
import CoreData
extension Todos {
@nonobjc public class func fetchRequest() -> NSFetchRequest<Todos> {
return NSFetchRequest<Todos>(entityName: "Todo")
}
@NSManaged public var text: String?
@NSManaged public var date: NSDate?
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment