Sets the data writer.
public setDataWriter ( Yosymfony\Spress\Core\DataWriter\DataWriterInterface $dataWriter ) | ||
$dataWriter | Yosymfony\Spress\Core\DataWriter\DataWriterInterface |
/** * Extract configuration and override the default DataWriter on startup * * @param EnvironmentEvent $event The start event */ public function onStart(EnvironmentEvent $event) { $configValues = $event->getConfigValues(); $configuration = new Configuration($configValues); $event->setConfigValues($configuration->get()); $event->setDataWriter(new FilesystemDataWriter($event->getDataWriter(), $configuration)); }