I have a dictionary of objects that need to be cleaned up before they are released. I have a method that does this for the entire dictionary. Before I release the dictionary in my -dealloc
method, I want to do the same thing. However, I am not sure of the state of the object during deallocation. In C# or Java, for instance, I would never call a method on the object being finalized, but I am not sure this applies to Objective C and deallocation. Is it acceptable to call the clean up method on self
during deallocation, or should I duplicate that functionality in my -dealloc
?