• iOS开发阶段技能总结


    这是一篇自己平时纪录的笔记...

    1.基本的数据结构常识:链表,队列,栈
    2.基本的算法:排序,动态规划等常用算法
    3.基本的概念,cocoa,各种自带的view的使用.
    4.xcode自带的测试:OCUnit
    5.xcode各种编译性能调试测试工具
    6.自带的oop编程思想,设计模式,runtime机制等动态语言特性
    7.各种开源的第三方代码框架
     
    知识点小结
     
    *高效使用xcode:
     
    *杨先生推荐
    使用restKit(https://github.com/RestKit/RestKit)
     
    *NSUserDefault注意事项:
    自定义存储对象存入userDefault中。
    主要方法:自定义的对象添加代理 NSCoding
    添加实现:
    - (void)encodeWithCoder:(NSCoder *)aCoder {
        [aCoder encodeObject:self.uid forKey:@"uid"];
    }
    - (id)initWithCoder:(NSCoder *)aDecoder {
        if (self = [super init]) {
            self.uid = [aDecoder decodeObjectForKey:@"uid"];
    }
    参考资料:
     
    *UITableView:(精通tableView,collectionView)
    cell自动计算高度大小:
    [self.protocalCell.contentView systemLayoutSizeFittingSize:UILayoutFittingCompressedSize].height + 1;
    cell移动,删除,添加,重加载:
    - (void)insertRowsAtIndexPaths:(NSArray *)indexPaths withRowAnimation:(UITableViewRowAnimation)animation;
    - (void)deleteRowsAtIndexPaths:(NSArray *)indexPaths withRowAnimation:(UITableViewRowAnimation)animation;
    - (void)reloadRowsAtIndexPaths:(NSArray *)indexPaths withRowAnimation:(UITableViewRowAnimation)animation NS_AVAILABLE_IOS(3_0);
    - (void)moveRowAtIndexPath:(NSIndexPath *)indexPath toIndexPath:(NSIndexPath *)newIndexPath NS_AVAILABLE_IOS(5_0);
    collectionView也是一样
     
    *检测软件使用是否会卡:(代码测试工具)
    KMCGeigerCounter
    参考资料:
     
    *保存照片到制定相册:
    类似有好多第三方的库,这个当时看着封装得很好...
     
    *RGB颜色转换:(宏定义的使用)
    #define UIColorFromRGB(rgbValue) [UIColor colorWithRed:((float)((rgbValue & 0xFF0000) >> 16))/255.0 green:((float)((rgbValue & 0x00FF00) >> 8))/255.0 blue:((float)(rgbValue & 0x0000FF))/255.0 alpha:1.0]
    使用:
    UIColorFromRGB(0x000000)
    代码中会自己定义很多宏,加快自己的编码速度...常见的还有各种Log,各种颜色标签,各种计算公式(系统的或是非系统的)...
     
    *打开系统设定位置的方法:(打开定位设定...)
     
    *UI分享:(新发现的别人的总结)
     
    * textfield:(黑方法)
    输入文本自动缩进几个单元,textfield.leftView
        UIView *ssview = [[UIView alloc] initWithFrame:CGRectMake(0, 0, 8, 5)];
        ssview.userInteractionEnabled = NO;
        self.addressField.leftView = ssview;
        self.addressField.leftViewMode = UITextFieldViewModeAlways;
     
    * navationItem缩进:(黑方法,还是遵循ios规范,使用appearance比较好)
    缩进自定义图形:btn.imageEdgeInsets = UIEdegeInsetsMake(0, -30, 0, 0)
     
    *网络优化:(貌似,我到现在都还没用上多少...一直没有做起来项目就挂掉...)
    1.降低数据包大小。2缓存。3.直接ip避免域名解析。4.压缩,加密。5.网络优化,这一点好,就是不同时发送太多http请求。ASIHTTPRequest
     
     * Xcode 带的LLDB 调试工具使用,推荐陈皓的教程:(数量掌握xcode工具)
     
  • 相关阅读:
    8.指针小结
    8.指针
    7.数组
    6.结构化程序设计
    python之迭代器
    1.python基础—有这篇文章足够
    python装饰器,细致讲解
    django客户管理系统-使用modelform对HTML标签统一添加样式
    python之md5使用方法
    git干货教程
  • 原文地址:https://www.cnblogs.com/Lxiaolong/p/4704483.html
Copyright © 2020-2023  润新知