Sunday, October 15, 2023
HomeiOS Developmentios - Can I declare a perform inside a category with out...

ios – Can I declare a perform inside a category with out physique in Swift?


So I used to be referring to the UIKit.UITableView file and I seen that each one the capabilities inside UITableView class are written with out their physique. I attempted to do the identical in my undertaking however Xcode would not let me achieve this. Can somebody clarify how was that potential within the supply file?

Beneath is a pattern snippet from there.

open func insertRows(at indexPaths: [IndexPath], with animation: UITableView.RowAnimation)

open func deleteRows(at indexPaths: [IndexPath], with animation: UITableView.RowAnimation)

@accessible(iOS 5.0, *)
open func moveRow(at indexPath: IndexPath, to newIndexPath: IndexPath)

@accessible(iOS 3.0, *)
open func reloadRows(at indexPaths: [IndexPath], with animation: UITableView.RowAnimation)



Supply hyperlink

RELATED ARTICLES

LEAVE A REPLY

Please enter your comment!
Please enter your name here

- Advertisment -
Google search engine

Most Popular

Recent Comments