public function writeToFile($filename, $data, $header = '')
    {
        $ini = $this->writeToString($data, $header);
        if (!file_put_contents($filename, $ini))
            throw new IniWritingException(sprintf('Impossible to write to file %s', $filename));
    }