嗨,我如何按天对我的数组进行排序,我从我的网络服务器(Json)中获取数据并解析到 NSDictionary 然后保存到 NSMutableArray ......我知道我需要实现
- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView
- 标题ForHeaderInSection:
- 部分行:
NSMutableArray 日志
2012-04-26 06:12:51.256 passingdata[91699:fb03] array : (
{
post = {
"CLASS_LEVEL" = "Intro/General";
"CLASS_TYPE" = "Muay Thai";
"DAY_OF_WEEK" = Sunday;
ID = 19;
"ORDER_BY" = 5;
TIME = "1:00pm - 2:30pm";
};
}
{
post = {
"CLASS_LEVEL" = "General/Intermediate/Advanced";
"CLASS_TYPE" = "Muay Thai Spar - Competitive";
"DAY_OF_WEEK" = Friday;
ID = 27;
"ORDER_BY" = 5;
TIME = "6:00pm - 9:00pm";
};
},
{
post = {
"CLASS_LEVEL" = "Fighters/Advanced/Intermediate";
"CLASS_TYPE" = "Fighters Training";
"DAY_OF_WEEK" = Monday;
ID = 1;
"ORDER_BY" = 1;
TIME = "9:30am - 11:00pm";
};
},
我可以在我的桌子上显示所有数据,但我想每天(周一,周二,周三..周日)按部分进行,我尝试了 NSpredicate 和 NSSet 但仍然无法正常工作。
我不知道如何按天对项目进行分组并获取所有信息以实现所有方法。
有任何想法吗 ??谢谢