You are here

public function ParserCSV::setColumnNames in Feeds 8.2

Specify an array of column names if you know them in advance, or FALSE (which is the default) to unset any prior column names. If no column names are set, the parser will put each row into a simple numerically indexed array. If column names are given, the parser will create arrays with these column names as array keys instead.

File

lib/Drupal/feeds/ParserCSV.php, line 65
Contains CSV Parser.

Class

ParserCSV
Functionality to parse CSV files into a two dimensional array.

Namespace

Drupal\feeds

Code

public function setColumnNames($columnNames) {
  $this->columnNames = $columnNames;
}