public function SpreadsheetIterator::getRowsCount in Migrate Spreadsheet 2.0.x
Same name and namespace in other branches
- 8 src/SpreadsheetIterator.php \Drupal\migrate_spreadsheet\SpreadsheetIterator::getRowsCount()
Gets the total number of rows in the worksheet.
Return value
int The total number of rows in the worksheet.
Overrides SpreadsheetIteratorInterface::getRowsCount
2 calls to SpreadsheetIterator::getRowsCount()
- SpreadsheetIterator::getOrigin in src/
SpreadsheetIterator.php - Retrieves the top-left origin of data area.
- SpreadsheetIterator::valid in src/
SpreadsheetIterator.php
File
- src/
SpreadsheetIterator.php, line 283
Class
- SpreadsheetIterator
- Provides a spreadsheet iterator.
Namespace
Drupal\migrate_spreadsheetCode
public function getRowsCount() : int {
if (!isset($this->cache['rows_count'])) {
$this->cache['rows_count'] = $this
->getWorksheet()
->getHighestDataRow();
}
return $this->cache['rows_count'];
}