NFePHP\Common\Files\FilesFolders::removeFile PHP Метод

removeFile() публичный статический Метод

removeFile
public static removeFile ( string $pathFile = '' ) : boolean
$pathFile string
Результат boolean
    public static function removeFile($pathFile = '')
    {
        if ($pathFile == '' || !is_file($pathFile)) {
            return true;
        }
        return unlink($pathFile);
    }

Usage Example

Пример #1
0
 /**
  * desativaContingencia
  * Desliga opção de contingência 
  * @return boolean
  */
 public function desativaContingencia()
 {
     $this->enableSVCAN = false;
     $this->enableSVCRS = false;
     $this->enableEPEC = false;
     $this->tsContingencia = 0;
     $this->motivoContingencia = '';
     $filename = NFEPHP_ROOT . DIRECTORY_SEPARATOR . 'config' . DIRECTORY_SEPARATOR . $this->aConfig['cnpj'] . '_contingencia.json';
     return Files\FilesFolders::removeFile($filename);
 }