Task/File/Csv/AbstractCsvTask.php
protected function initFile(ProcessState $state)
    {
        if ($this->csv) {
            return;
        }
        $options = $this->getOptions($state);
        $headers = $this->getHeaders($state, $options);
        $this->csv = new CsvFile(
            $options['file_path'],
            $options['delimiter'],
            $options['enclosure'],
            $options['escape'],
            $headers,
            $options['mode']
        );
    }
protected function initFile(ProcessState $state)
    {
        if ($this->csv) {
            return;
        }
        $options = $this->getOptions($state);
        $headers = $this->getHeaders($state, $options);
        $this->csv = new CsvFile(
            $options['file_path'],
            $options['delimiter'],
            $options['enclosure'],
            $options['escape'],
            $headers,
            $options['mode']
        );
    }
@param ProcessState $state

@throws \UnexpectedValueException
@throws \Symfony\Component\OptionsResolver\Exception\ExceptionInterface
@throws \RuntimeException