[:en]Swift: save, recall & delete data[:]

[:en]To handling local data:


//Save data:
defaults.setValue(responsContent!, forKey: "key")



//Recall data
let mySaveddata = NSUserDefaults.standardUserDefaults().stringForKey("key")


//Empty data:
  NSUserDefaults.standardUserDefaults().removeObjectForKey("key")

[:]

Print Friendly, PDF & Email
Scroll to Top