随笔分类 -  ios

ios wrriting from work!
摘要:AppDelegate *appDelegate =[[UIApplicationsharedApplication] delegate]; NSManagedObjectContext *context = [appDelegate managedObjectContext]; //classes NSEntityDescription *entityDescriptionForClass = [NSEntityDescription entityForName:@"ClassEntity" inManagedObjectContext:context]; NSFetch 阅读全文
posted @ 2012-07-14 09:29 zander 阅读(236) 评论(0) 推荐(0)
摘要:0x6d27c50 <x-coredata://1CE5BD28-F4A6-422A-B4DD-9342939F3B9E/ClassEntity/p1> 阅读全文
posted @ 2012-07-13 18:15 zander 阅读(185) 评论(0) 推荐(0)
摘要:NsArray存放固定的数据,提供修改数据的方法极少,NsMutableArray提供了很多修改数据的方法,如果要频繁修改数组内部的数据那就得定义成NsMutableArray,但是一些需要NsArray类型作为参数的方法,NsMutableArray和NsArray都是适用的。链表和数组的区别。 动态和静态的区别。 阅读全文
posted @ 2012-07-13 11:35 zander 阅读(256) 评论(0) 推荐(0)
摘要:只有使用core data 对数据库进行一此操作的时候才会 生成.sqlite文件 坑爹 阅读全文
posted @ 2012-07-12 16:36 zander 阅读(155) 评论(0) 推荐(0)
摘要:NSManagedObject 托管的数据模型 的 数据类型可以采取这种方式来存取(NSManagedObject对象的方法:)valueForKey:@"lineNum" lineNum为数据模型的一个property 阅读全文
posted @ 2012-07-11 17:02 zander 阅读(251) 评论(0) 推荐(0)
摘要:代理 先判断 1. 有几个section 2. 每个section 多少个cell如果 设置的值都为0 那么就不执行-(UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath{}这个方法了-(NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section{ NSLog(@"numberOfRowsInSection返回为0的时候就不用执 阅读全文
posted @ 2012-07-11 10:19 zander 阅读(4366) 评论(0) 推荐(0)