func toJSONString(dict:NSDictionary?)->String{
let data = try? NSJSONSerialization.dataWithJSONObject(dict!, options: NSJSONWritingOptions.PrettyPrinted)
let strJson = NSString(data: data!, encoding: NSUTF8StringEncoding)
return strJson! as String
}
网友评论