1.NSData NSData是Objective-C语言中数据的基本类型,其成分可以理解为字节指针和长度的封装的类,来看看源代码 @interface NSData : NSObject <NSCopying, NSMutableCopying, NSSecureCoding> @property (readonly) NSUInteger length; /* The -bytes method returns a pointer to a contiguous region of mem…
Archiving Objective-C Objects with NSCoding For the seasoned Cocoa developer, this is a piece of cake. For newer developers, this can be a real pain, especially if you don’t know what you’re looking for. I get this question a decent amount, so I figu…
一.NS_DESIGNATED_INITIALIZER 用来修饰init方法,被修饰的方法称为designated initializer:没有被这个修饰的init方法称为convenience initializer 参考1对之的说明为 1.A designated initializer must call (via super) a designated initializer of the superclass. Where NSObject is the superclass thi…