上一页 1 ··· 4 5 6 7 8 9 10 11 12 下一页

2018年3月6日

iOS开发 - Protocol协议及委托代理(Delegate)

摘要: 因为Object-C是不支持多继承的,所以很多时候都是用Protocol(协议)来代替。Protocol(协议)只能定义公用的一套接口,但不能提供具体的实现方法。也就是说,它只告诉你要做什么,但具体怎么做,它不关心。 当一个类要使用某一个Protocol(协议)时,都必须要遵守协议。比如有些必要实现 阅读全文

posted @ 2018-03-06 16:47 东方🐺 阅读(395) 评论(1) 推荐(0) 编辑

Objective-C Inheritance

摘要: One of the most important concepts in object-oriented programming is that of inheritance. Inheritance allows us to define a class in terms of another 阅读全文

posted @ 2018-03-06 16:09 东方🐺 阅读(213) 评论(0) 推荐(0) 编辑

内存调试工具说明-演示

摘要: 在开发过程中,有时我们会遇到内存泄漏的情况。苹果提供了一个强大Instruments工具来检测iOS应用内存泄漏情况。 以下对Instruments工具进行简单说明,通过实例演示检测内存泄漏的问题。 Instruments工具 Instruments是用于动态调追踪和分析OS X和iOS的代码的性能 阅读全文

posted @ 2018-03-06 15:48 东方🐺 阅读(375) 评论(0) 推荐(0) 编辑

iOS 自适应高度,改变字体颜色

摘要: #define kMainBoundsWidth ([UIScreen mainScreen].bounds).size.width //屏幕的宽度 #define kFont [UIFont systemFontOfSize:17.f] //字体大小 #define kLineSpacing 7 //行间距 - (void)view... 阅读全文

posted @ 2018-03-06 15:34 东方🐺 阅读(444) 评论(0) 推荐(0) 编辑

2018年3月5日

iOS --runtime理解

摘要: iOS~runtime理解 Runtime是想要做好iOS开发,或者说是真正的深刻的掌握OC这门语言所必需理解的东西。最近在学习Runtime,有自己的一些心得,整理如下,一为 查阅方便二为 或许能给他人一些启发,三为 希望得到大家对这篇整理不足之处的一些指点。 什么是Runtime 我们写的代码在 阅读全文

posted @ 2018-03-05 15:46 东方🐺 阅读(360) 评论(0) 推荐(0) 编辑

2018年2月27日

Objective-C Composite Objects

摘要: We can create subclass within a class cluster that defines a class that embeds within it an object. These class objects are composite objects. So you 阅读全文

posted @ 2018-02-27 15:41 东方🐺 阅读(224) 评论(0) 推荐(0) 编辑

iOS 自定义读写文件

摘要: LSCacheFile.h LSCacheFile.m 阅读全文

posted @ 2018-02-27 14:19 东方🐺 阅读(370) 评论(0) 推荐(0) 编辑

NSArray 自定义封装

该文被密码保护。 阅读全文

posted @ 2018-02-27 11:26 东方🐺 阅读(6) 评论(0) 推荐(0) 编辑

Objective-C Data Encapsulation

摘要: All Objective-C programs are composed of the following two fundamental elements: Program statements (code): This is the part of a program that perform 阅读全文

posted @ 2018-02-27 10:44 东方🐺 阅读(261) 评论(0) 推荐(0) 编辑

2018年2月24日

NSTimer 实现时钟回调方法

摘要: 在开发过程中,发现时钟调用的地方比较多。所以对时钟进行了一个简单的统一封装。具体代码如下: 1、时钟回调函数的声明: 2、时钟回调函数的实现: 阅读全文

posted @ 2018-02-24 13:38 东方🐺 阅读(456) 评论(0) 推荐(0) 编辑

上一页 1 ··· 4 5 6 7 8 9 10 11 12 下一页

导航