alloc is a class selector (which, for example, is called similar)
[NSObject alloc]
It returns an uninitialized pointer of type NSObject *.
To complete the initialization, you must call the appropriate designated initializer in the instance itself:
[[NSObject alloc] init]
Will return a useful NSObject * pointer.
The new one basically does alloc โ init, except that it is called directly at the class level:
NSObject* aObj = [NSObject new] NSObject* aObj = [[NSObject alloc] init]
Are similar.
A non-atomic property means that when a property is written (ex during a given call) , no lock will be added to the variable synthesized by this property (this means that you do not need to overload @synchronize time).
So, if your property is not changed by different threads at the same time, you can safely set it to non-atomic.
The copy property means that when this property is changed ex:
aObj.copyProperty = otherValue
The copyProperty variable will send a copyWithZone: signal to the otherValue object.
In other words, if your copyProperty is compatible with the NSCopying protocol, it will ultimately have the same properties as otherValue, but will have its own address and store the counter and therefore be in a completely different part of the memory, since there was anotherValue.
Basically copyProperty will take up as much memory space as otherValue.
Assigning a property means when you do:
aObj.prop = aProperty
A variable synthesized using the prop property will be directly assigned to aProperty, meaning that they will pass the exact same address and keep count .
Extra memory space is not used when you use assignment.
Hope this helps you. For more information, please read the Apple Memory Management Documentation.