String轉(zhuǎn)NSData
let data = string.dataUsingEncoding(NSUTF8StringEncoding)
NSData轉(zhuǎn)String
let string = String(data: data, encoding: NSUTF8StringEncoding)
String轉(zhuǎn)NSData
let data = string.dataUsingEncoding(NSUTF8StringEncoding)
NSData轉(zhuǎn)String
let string = String(data: data, encoding: NSUTF8StringEncoding)