src/Writer/FileWriter.php
public function write(array $data, array $options)
    {
        if (!isset($options['file'])) {
            throw new \InvalidArgumentException(
                'Parameter "file" is mandatory.'
            );
        }

        if (!is_string($options['file'])) {
            throw new \InvalidArgumentException(
                'Parameter "file" must be a string.'
            );
        }

        $file = $this->_factory->createInstance($options['file'], null, $options);

        $file->setContents($data)
            ->save($options);
    }
public function write(array $data, array $options)
    {
        if (!isset($options['file'])) {
            throw new \InvalidArgumentException(
                'Parameter "file" is mandatory.'
            );
        }

        if (!is_string($options['file'])) {
            throw new \InvalidArgumentException(
                'Parameter "file" must be a string.'
            );
        }

        $file = $this->_factory->createInstance($options['file'], null, $options);

        $file->setContents($data)
            ->save($options);
    }
This method writes the configuration to a file.

@param array $data    - Data.
@param array $options - Options.

@throws \InvalidArgumentException

@return array