IOS经常使用的性能优化策略
2017-06-10 15:45
218 查看
1、用ARC管理内存
2、对于UITableView使用重用机制
3、UIView及其子类设置opaque=true
4、主进程是用来绘制UI的,所以不要堵塞
5、慎用XIB,由于XIB创建UIViewController时。会将xib上的全部内容导入到内存
6、选择正确集合
Arrays:有序的值的列表。用index高速查找,通过值查找慢,insert/delete操作慢。
Dictionaries:存储键/值对.用index高速查找。
Sets: 无序的值列表。
通过值高速查找,insert/delete快。
7、启用gzip压缩
iOS早已默认支持GZIP压缩
8、延迟创建
2、对于UITableView使用重用机制
3、UIView及其子类设置opaque=true
4、主进程是用来绘制UI的,所以不要堵塞
5、慎用XIB,由于XIB创建UIViewController时。会将xib上的全部内容导入到内存
6、选择正确集合
Arrays:有序的值的列表。用index高速查找,通过值查找慢,insert/delete操作慢。
Dictionaries:存储键/值对.用index高速查找。
Sets: 无序的值列表。
通过值高速查找,insert/delete快。
7、启用gzip压缩
iOS早已默认支持GZIP压缩
8、延迟创建
相关文章推荐
- 高仿新浪微博iOS项目实战(数据库建模、UI设计、动画优化、性能优化、控件使用)
- iOS性能优化:Instruments使用实战
- iOS性能优化:Instruments使用实战
- iOS性能优化---转载《三》一次对MKMapView的性能优化(instrments core animation 使用)
- iOS开发中UITableview控件的基本使用及性能优化方法
- iOS性能优化策略
- iOS性能优化:Instruments使用实战
- iOS性能优化之内存管理:Analyze、Leaks、Allocations的使用和案例代码
- iOS性能优化:Instruments使用实战
- iOS性能优化:Instruments使用实战
- iOS性能优化策略
- iOS性能优化:Instruments使用实战
- iOS性能优化:Instruments使用实战
- SQL优化策略高级优化经常使用-1(The Return Of The King)
- iOS性能优化:Instruments使用实战
- IOS常用的性能优化策略
- iOS性能优化:Instruments使用实战
- iOS性能优化:Instruments使用实战
- iOS性能优化:Instruments使用实战
- iOS性能优化之内存管理:Analyze、Leaks、Allocations的使用和案例代码