You are here

public function DrupalTempFileAdapter::__construct in Backup and Migrate 8.4

Construct a manager.

Parameters

\Drupal\Core\File\FileSystem $filesystem: A file path or stream URL for the temp directory.

string $dir: The directory to save to.

string $prefix: A string prefix to add to each created file.

Overrides TempFileAdapter::__construct

File

src/File/DrupalTempFileAdapter.php, line 33

Class

DrupalTempFileAdapter
Class DrupalTempFileAdapter.

Namespace

BackupMigrate\Drupal\File

Code

public function __construct(FileSystemInterface $filesystem, $dir = 'temporary://', $prefix = 'bam') {

  // Set the prefix and initialize the temp file tracking.
  parent::__construct($dir, $prefix);
  $this->filesystem = $filesystem;
}