Chapter 19. Displaying details of your LioN
This chapter covers
- Optionals
- Typecasting
- Optional binding
If you open the Contacts app on your iPhone, you’ll notice that your contacts are displayed using a table view, and individual contacts are in a tableView cell. If you select one of those cells, another page loads with the details of that contact, and you can edit the contact if you choose. You’re going to add the same type of functionality to your LioN app now.
19.1. Capturing the tapped row index
The first thing you need to do in order to display the details of a specific row is to capture which row the user tapped. If only there was a function that already captured this information! Oh, wait—there is. Open your MainViewController ...
Get Anyone Can Create an App now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.