ILIAS  release_5-4 Revision v5.4.26-12-gabc799a52e6
Twig_Tests_FilesystemHelper Class Reference
+ Collaboration diagram for Twig_Tests_FilesystemHelper:

Static Public Member Functions

static removeDir ($dir)
 

Detailed Description

Definition at line 12 of file FilesystemHelper.php.

Member Function Documentation

◆ removeDir()

static Twig_Tests_FilesystemHelper::removeDir (   $dir)
static

Definition at line 14 of file FilesystemHelper.php.

References $filename.

Referenced by Twig_Tests_Cache_FilesystemTest\tearDown(), Twig_Tests_FileCachingTest\tearDown(), and Twig_Tests_EnvironmentTest\testExtensionsAreNotInitializedWhenRenderingACompiledTemplate().

15  {
16  $iterator = new RecursiveIteratorIterator(new RecursiveDirectoryIterator($dir, PHP_VERSION_ID < 50300 ? 0 : FilesystemIterator::SKIP_DOTS), RecursiveIteratorIterator::CHILD_FIRST);
17  foreach ($iterator as $filename => $fileInfo) {
18  if ($iterator->isDot()) {
19  continue;
20  }
21 
22  if ($fileInfo->isDir()) {
23  rmdir($filename);
24  } else {
25  unlink($filename);
26  }
27  }
28  rmdir($dir);
29  }
$filename
Definition: buildRTE.php:89
+ Here is the caller graph for this function:

The documentation for this class was generated from the following file: