如何在 swift 中更改 UISearchController 行的高度

How can i change the UISearcherController row's height in swift

如何在 swift 中更改 searchController 的行高?我已经用 searchController 设置了一个 tableview,我想让行高一点。那太好了。

// swift 2.3
1. set tableView delegate

tableView.delegate = self

2. implementes the delegate method

extension ViewController: UITableViewDelegate {
    func tableView(tableView: UITableView, 
           heightForRowAtIndexPath indexPath: NSIndexPath) -> CGFloat {
        return 50
    }
}

// swift 3.0
1. set tableView delegate

tableView.delegate = self

2. implementes the delegate method

extension ViewController: UITableViewDelegate {
    func tableView(_ tableView: UITableView, 
                  heightForRowAt indexPath:IndexPath) -> CGFloat {
        return 200
    }
}