iaPatchApplier::_writeFile PHP Method

_writeFile() protected method

protected _writeFile ( $filename, $content, $isBinary )
    protected function _writeFile($filename, $content, $isBinary)
    {
        $mode = $isBinary ? 'b' : 't';
        $file = @fopen($filename, 'w' . $mode);
        if (is_resource($file)) {
            fwrite($file, $content);
            fclose($file);
            $this->_logInfo('File successfully written: :file', self::LOG_SUCCESS, array('file' => $filename));
            return;
        }
        $this->_logInfo('Unable to write the file: :file', self::LOG_ERROR, array('file' => $filename));
    }