What is the difference between strong vs copy in objective-c? Which one should i be using?
I know copy prevents the value of the instance variable from changing if set with a mutable string that is later changed itself. Anything else?
What is the difference between strong vs copy in objective-c? Which one should i be using?
I know copy prevents the value of the instance variable from changing if set with a mutable string that is later changed itself. Anything else?
strong
increases retain counter of an object by 1.
copy
creates an object's copy with retain counter 1.
If you use ARC you can't access to retain counter, but the approach is the same as for MRC.