class CsvTableWriter implements TableWriter (View source)

Methods

public
__construct($filename)

No description

public
start(array $columns)

Start writing, declaring the columns that will be provided.

public
finish()

Finish writing.

public
writeRecord(array $record)

Write a single record.

Details

__construct($filename)

No description

Parameters

$filename

start(array $columns)

Start writing, declaring the columns that will be provided.

Must be called before writeRecord()

Parameters

array $columns

The columns to be provided as keys in writeRecord() calls

finish()

Finish writing.

writeRecord() must not be called after this

writeRecord(array $record)

Write a single record.

Parameters

array $record

A map of column => value data