UIPickerViewDataSource is an iOS protocol for defining methods instructing a UIPickerView how many components and rows it should display.
UIPickerViewDataSource
is an iOS protocol defining methods instructing a UIPickerView
how many components and rows it should display. A picker view can have 1 or more components (the wheels in a slot-machine metaphor), each with an independent number of rows (the writing on the wheels). Two methods return these values:
numberOfComponentsInPickerView:
- returns the number of wheelspickerView:numberOfRowsInComponent:
- returns the number of rows for a given wheel
For more information, please refer to the Apple Documentation for UIPickerViewDataSource
.