interface ArchiverInterface in Drupal 10
Same name and namespace in other branches
- 8 core/lib/Drupal/Core/Archiver/ArchiverInterface.php \Drupal\Core\Archiver\ArchiverInterface
- 9 core/lib/Drupal/Core/Archiver/ArchiverInterface.php \Drupal\Core\Archiver\ArchiverInterface
Defines the common interface for all Archiver classes.
Hierarchy
- interface \Drupal\Core\Archiver\ArchiverInterface
Expanded class hierarchy of ArchiverInterface
All classes that implement ArchiverInterface
See also
\Drupal\Core\Archiver\ArchiverManager
\Drupal\Core\Archiver\Annotation\Archiver
1 file declares its use of ArchiverInterface
- UpdateTestArchiver.php in core/
modules/ update/ tests/ modules/ update_test/ src/ Plugin/ Archiver/ UpdateTestArchiver.php
3 string references to 'ArchiverInterface'
- drupal7.php in core/
modules/ tracker/ tests/ fixtures/ drupal7.php - A database agnostic dump for testing purposes.
- drupal7.php in core/
modules/ rdf/ tests/ fixtures/ drupal7.php - A database agnostic dump for testing purposes.
- drupal7.php in core/
modules/ migrate_drupal/ tests/ fixtures/ drupal7.php - A database agnostic dump for testing purposes.
File
- core/
lib/ Drupal/ Core/ Archiver/ ArchiverInterface.php, line 12
Namespace
Drupal\Core\ArchiverView source
interface ArchiverInterface {
/**
* Adds the specified file or directory to the archive.
*
* @param string $file_path
* The full system path of the file or directory to add. Only local files
* and directories are supported.
*
* @return $this
* The called object.
*/
public function add($file_path);
/**
* Removes the specified file from the archive.
*
* @param string $path
* The file name relative to the root of the archive to remove.
*
* @return $this
* The called object.
*/
public function remove($path);
/**
* Extracts multiple files in the archive to the specified path.
*
* @param string $path
* A full system path of the directory to which to extract files.
* @param array $files
* Optionally specify a list of files to be extracted. Files are
* relative to the root of the archive. If not specified, all files
* in the archive will be extracted.
*
* @return $this
* The called object.
*/
public function extract($path, array $files = []);
/**
* Lists all files in the archive.
*
* @return array
* An array of file names relative to the root of the archive.
*/
public function listContents();
}