public function Tar::extract

Implements Drupal\Component\Archiver\ArchiveInterface::extract().

Overrides ArchiverInterface::extract

File

drupal/core/lib/Drupal/Component/Archiver/Tar.php, line 60
Definition of Drupal\Component\Archiver\Tar.

Class

Tar
Defines a archiver implementation for .tar files.

Namespace

Drupal\Component\Archiver

Code

public function extract($path, array $files = array()) {
  if ($files) {
    $this->tar
      ->extractList($files, $path);
  }
  else {
    $this->tar
      ->extract($path);
  }
  return $this;
}