UITableViewDelegate doesn't formally define important methods called during table reordering (Dupe of rdar://21813508)

Originator:Steaps.4
Number:rdar://32378647 Date Originated:24-May-2017 12:13 PM
Status:Open Resolved:
Product:iOS + SDK Product Version:iOS 2 - iOS 10
Classification:Enhancement Reproducible:Always
 
Summary:
Dupe of rdar://21813508

UITableView calls several methods on its delegate which are not a formal part of UITableViewDelegate and are not documented:
-tableView:willBeginReorderingRowAtIndexPath:
-tableView:didEndReorderingRowAtIndexPath:
-tableView:didCancelReorderingRowAtIndexPath:
These methods provide an important ability for applications to appropriately respond to user reordering the table, which would be otherwise implemented poorly or in a fragile way, leading to bad user experience. These methods are not private API per se, as they *are called* by the SDK, not the other way around, so it's possible to use these methods successfully already, but ideally they should be documented, so that developers would be aware of the possibilities.

Steps to Reproduce:
1. Build a simple iOS app with a view controller containing a UITableView and serving as a delegate and data source of that table.
2. Enable reordering of contents of the table by implementing necessary data source and delegate methods.
3. Implement the methods described above in the view controller (the table's delegate).
4. Launch the app and try reordering the rows.
5. The undocumented methods get called at appropriate moments.

Expected Results:
Described reordering-related methods should be part of the formal UITableViewDelegate protocol and documented.

Actual Results:
Described reordering-related methods are not part of the protocol, not documented and are arcane word-of-the-mouth magic known only to a few lucky developers.

Version:
iOS 2 - iOS 10

Notes:
As far as I know, these methods were "available" as long as UITableView was around and still are. The attached project demonstrates how these delegate methods can be used (look at the bottom of MasterViewController.m).

Added: original Radar has a sample project. These methods are still called as of iOS 10.3.2

Comments


Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!