Difference between retain and assign ?
Answer / babu
Assign and retain was used in manual memory management (MRC) environment.
assign to set a property’s pointer to the address of the object without retaining it. use weak to have the property point to nil automatically if the object assigned to it is deallocated .
Use retain by default and will manage the object’s reference count automatically whether another object is assigned to the property or it’s set to nil; In ARC you will use strong instead of retain.
| Is This Answer Correct ? | 0 Yes | 0 No |
What is difference between nsnotification and delegate?
What is active state in ios?
How to send your device id to an iphone developer?
What is the difference between viewdidload and viewdidappear?
Explain retain counts in iOS operating system?
Define cocoa?
Explain difference between coredata & sqlite?
Can apk files run on ios?
Explain about Viewcontroller lifecycle.
What is code signing in iOS operating system?
What is nsmanagedobjectmodel?
What is the purpose of using ibaction and iboutlet?