Alloc: method of the NSObject class. Returns a new instance of the receiving class.
Init : An instance method of NSObject. Implemented by subclasses to initialize a new object (receiver) immediately after allocating memory for it.
New : Class method NSObject. Selects a new instance of the receiving class, sends it an initialization message, and returns an initialized object.
Release : NSObject delegate instance method. Decreases the recipient reference count.
Auto-release : NSObject delegate instance method. Adds the recipient to the current automatic release pool.
Save: The instance method of the NSObject delegate. Increases the recipient reference count.
Copy: the instance method of the NSObject delegate. Returns a new instance that is a copy of the recipient.
So, in conclusion, we can say that
alloc goes with init
new = alloc + init
Shantanu Jun 29 2018-12-12T00: 00Z
source share