• Модуль: sale
  • Путь к файлу: ~/bitrix/modules/sale/lib/location/util/csvreader.php
  • Класс: BitrixSaleLocationUtilCSVReader
  • Вызов: CSVReader::ReadBlockLowLevel
public function ReadBlockLowLevel(&$bytesRead = false, $lineLimit = false)
{
	if(trim($this->header[0]) == 'en' && !isset($this->header[1]))
	{
		$this->legacy = true;
		$this->SetDelimiter(",");
	}

	if($bytesRead !== false)
		$this->SetPos($bytesRead);

	$result = array();
	$i = -1;
	while ($line = $this->FetchAssoc())
	{
		$i++;

		if($lineLimit !== false && $lineLimit + 1 == $i)
			break;

		if(!$i && !$bytesRead)
		{
			continue; // header, skip
		}

		$result[] = $line;

		if($bytesRead !== false)
			$bytesRead = $this->GetPos();
	}

	return $result;
}