1.字符串转字典
NSString * jsonString = @"";
NSData *jsonData = [jsonString dataUsingEncoding:NSUTF8StringEncoding];
NSDictionary *dic = [NSJSONSerialization JSONObjectWithData:jsonData options:NSJSONReadingMutableContainers error:&err];
2.字典转字符串
SData *jsonData = [NSJSONSerialization dataWithJSONObject:dic options:NSJSONWritingPrettyPrinted error:&parseError];
NSString * str = [[NSString alloc] initWithData:jsonData encoding:NSUTF8StringEncoding];