摘要:
1.使用序列化需要在对象中实现NSCoding协议NSCoding协议方法:encodeWithCoder和initWithCoder,将一个对象序列化需要实现这2个方法。@protocol NSCoding- (void)encodeWithCoder:(NSCoder *)aCoder;-(vo... 阅读全文
摘要:
@interface ViewController ()#define FileName @"Student.plist"#define KName @"KName"#define KBirth @"KBirth"#define KSex @"KSex"#define KNumber @"KNumb... 阅读全文
摘要:
1.每个应用程序都有自己的存储空间。2.应用程序不能访问其他程序的存储空间。3.应用程序请求的数据都要通过权限检测,不符合条件的不被允许。默认,沙盒有3个目录:Documents:应用程序将其数据存储在documents中。Library:基于NSUserDefaults的首选项设置存储在Libra... 阅读全文
摘要:
1.Push跳转- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath { static NSString *cellKey=@"cellKey... 阅读全文
摘要:
重载函数:-(NSArray *) sectionIndexTitlesForTableView: (UITableView *) tableView{ //dict allKeys取出的key arr无顺序,需进行排序 NSArray *arr = [[self.words allKeys] ... 阅读全文
摘要:
1.代理 UITableViewDelegate,UITableViewDataSource2.实现代理- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView{ return 1; //分区数,默认为1}- (NSI... 阅读全文
摘要:
UIDatePicker属性:Mode:Date and TimeLocale:Interval:最大值,最小值 NSDate *date=[self.dataPicker date]; NSDateFormatter *formatter=[[NSDateFormatter alloc... 阅读全文
摘要:
1.组成最下层是:tabbar 中间是:custom content 最上面:Tab bar controller viewTab Bar上面显示的每一个Tab都对应着一个View Controller.ViewController本身具有一个tabBarItem属性,只要设置它,就能改变Tab B... 阅读全文