Performs any clean up necessary to prepare the view for use again.
- iOS 6.0+
- tvOS 9.0+
The default implementation of this method does nothing. However, when overriding this method, it is recommended that you call
super anyway. Subclasses such as
UICollection override this method and use it to perform relevant actions. So if your subclass descends from
UICollection or some other intermediate class, calling
super ensures that your class gets the parent’s behavior.
When a view is dequeued for use, this method is called before the corresponding dequeue method returns the view to your code. Subclasses can override this method and use it to reset properties to their default values and generally make the view ready to use again. You should not use this method to assign any new data to the view. That is the responsibility of your data source object.