I am a bit confused about the objects which are initialized by type-casting. Like
UITextField *txtFld = (UITextField *)[self.view viewWithTag:someTag];
//
//
//some code here for this text field usage
//
//
now when I am finished using this text field should I set it to nil or leave it as it is for the system to take care of it.
Now in the case of the objects of a database class(using sqlite) I create an object like
DatabaseClass *dbObj = (DatabaseClass *)[[appDelegateObject dbObjArray] objectAtIndex:index];
Should I set it to nil too after I am finished with this object
or should initialize the object like:
DatabaseClass *dbObj = (DatabaseClass *)[[[appDelegateObject dbObjArray] objectAtIndex:index] retain];
and then release it and finally set it to nil.