You are here

private function testDataFileIterator::_parseNextDataset in Loft Data Grids 6.2

Same name and namespace in other branches
  1. 7.2 vendor/phpoffice/phpexcel/unitTests/testDataFileIterator.php \testDataFileIterator::_parseNextDataset()
2 calls to testDataFileIterator::_parseNextDataset()
testDataFileIterator::next in vendor/phpoffice/phpexcel/unitTests/testDataFileIterator.php
testDataFileIterator::rewind in vendor/phpoffice/phpexcel/unitTests/testDataFileIterator.php

File

vendor/phpoffice/phpexcel/unitTests/testDataFileIterator.php, line 48

Class

testDataFileIterator

Code

private function _parseNextDataset() {

  //    Read a line of test data from the file
  do {

    //    Only take lines that contain test data and that aren't commented out
    $testDataRow = trim(fgets($this->file));
  } while ($testDataRow > '' && $testDataRow[0] === '#');

  //    Discard any comments at the end of the line
  list($testData) = explode('//', $testDataRow);

  //    Split data into an array of individual values and a result
  $dataSet = $this
    ->_getcsv($testData, ',', "'");
  foreach ($dataSet as &$dataValue) {
    $dataValue = $this
      ->_parseDataValue($dataValue);
  }
  unset($dataValue);
  return $dataSet;
}