iOS:NSObject数据映射错误

时间:2016-01-20 21:30:03

标签: ios pagination tableview

iOS社区
我读了类似的问题但无法找到解决方案 我开始着手建模NSObject的子类 但是映射给了我一些错误,我不明白这个逻辑,请帮我理解




  [manager GET:urlstring parameters:nil progress:nil success:^(NSURLSessionTask * task, id responseObject)
     {
         NSLog(@"%@",responseObject);

         _totalPages = [[responseObject objectForKey:@"totalPages"]integerValue];

         for (int i=0;i<[[responseObject valueForKey:@"items"]count];i++)

         {
             NSLog(@"Number of items are:%d",[[responseObject valueForKey:@"items"]count]);

             Listing_Ads * ads = [[Listing_Ads alloc] initWithDictionary:[responseObject valueForKey:@"items"]];

            if (![self.ads_Array containsObject:ads])
             {
                 [self.ads_Array addObject:ads];
             }


         }




Listing_Ads

作为回应,我在-[__NSArrayI length]: unrecognized selector sent to instance 0x7cadabc0

中定义了每个属性10个值

错误是:

{{1}}

0 个答案:

没有答案