I feel like sorting could be part of Data provider, this due to the fact that sorting involves:
-Affect provider data
-Affect UITableView elements UI (order of the cells, with possible animations)
-Involves boilerplate code (for both the insertion and animations)
That said my proposal is:
Add a sorting method to Provider class where it would receive a sorting closure and a "animated" boolean parameter.
I feel like sorting could be part of Data provider, this due to the fact that sorting involves: -Affect provider data -Affect UITableView elements UI (order of the cells, with possible animations) -Involves boilerplate code (for both the insertion and animations)
That said my proposal is: Add a sorting method to Provider class where it would receive a sorting closure and a "animated" boolean parameter.
What are your thoughts on this?