Instance Method

numberOfRows(inSection:)

Returns the number of rows (table cells) in a specified section.

Declaration

func numberOfRows(inSection section: Int) -> Int

Parameters

section

An index number that identifies a section of the table. Table views in a plain style have a section index of zero.

Return Value

The number of rows in the section.

Discussion

UITableView gets the value returned by this method from its data source and caches it.

See Also

Getting the Number of Rows and Sections

var numberOfSections: Int

The number of sections in the table view.

Beta Software

This documentation contains preliminary information about an API or technology in development. This information is subject to change, and software implemented according to this documentation should be tested with final operating system software.

Learn more about using Apple's beta software