Notification function called just before an object is deleted from memory.
An object is deleted when its reference count reaches 0.
The default implementation of this function does nothing. This function can be overridden in custom classes.