iOS Json转字典

//json转字典
-(NSDictionary *) JSONStringToDictionaryWithData:(NSString *)data{
    NSError * error;
    NSData * m_data = [data  dataUsingEncoding:NSUTF8StringEncoding];
    NSDictionary *dict = [NSJSONSerialization  JSONObjectWithData:m_data options:NSJSONReadingMutableContainers error:&error];
    return dict;
}

你可能感兴趣的:(iOS Json转字典)