Итак, я пытаюсь получить значение textLabel строки, которую я выбираю. Я попробовал распечатать его, но это не сработало. После некоторых исследований выяснилось, что этот код работал, но только в Objective-C;
- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath
{
NSLog(@"did select and the text is %@",[tableView cellForRowAtIndexPath:indexPath].textLabel.text);]
}
Я не мог найти решение для Swift. Возможно, печать indexpath.row возможна, но это не то, что мне нужно.
так что мне делать? или что такое "Swift-версия" этого кода?