daily pastebin goal
82%
SHARE
TWEET

Untitled

a guest Jan 22nd, 2018 54 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. let appDelegate = UIApplication.shared.delegate as! AppDelegate
  2.         let context = appDelegate.persistentContainer.viewContext
  3.        
  4.         let entity = NSEntityDescription.entity(forEntityName: "HospitalLocations", in: context)
  5.         let newHospital = NSManagedObject(entity: entity!, insertInto: context)
  6.        
  7.         newHospital.setValue("Livanta", forKey: "hospital_name")
  8.         newHospital.setValue("Maryland", forKey: "hospital_state")
  9.         newHospital.setValue(39.051599499999995, forKey: "hospital_lat")
  10.         newHospital.setValue(-76.49555090000001, forKey: "hospital_lng")
RAW Paste Data
Top