34,333
edits
Changes
→UIPickerView Delegate and DataSource
* '''numberOfComponentsInPickerView:''' - Called by the PickerView to identify the number of components (i.e. selection wheels) that are to be displayed to the user.
* '''numberOfRowsInComponent:''' - Informs the PickerView of the number of rows (in other words the selection options) that are present in a specified component.
In addition to a data source, the PickerView also needs a mechanism for notifying the application code when a selection has been made by the user. It achieves this by calling the didSelectRow method of the class declared as the PickerView’s delegate.