美文网首页
iOS字符串或者Data转Dictionary

iOS字符串或者Data转Dictionary

作者: iOS_zy | 来源:发表于2023-09-13 19:02 被阅读0次

今天遇到个棘手的问题,
假如有个数据是:
{a:123, c:123 ,b:123}
系统自带的:
NSDictionary *resposeJson = [NSJSONSerialization JSONObjectWithData:responseObject options:NSJSONReadingAllowFragments error:nil];
转出来之后就是:
{a:123 ,b:123, c:123}
key会自动排序。

谁知道怎么能让key不排序转出来?

相关文章

网友评论

      本文标题:iOS字符串或者Data转Dictionary

      本文链接:https://www.haomeiwen.com/subject/tvppvdtx.html