You are here

public function DirectoryDestination::fileExists in Backup and Migrate 8.4

Does the file with the given id (filename) exist in this destination.

Parameters

string $id The id (usually the filename) of the file.:

Return value

bool True if the file exists, false if it does not.

Overrides ReadableDestinationInterface::fileExists

2 calls to DirectoryDestination::fileExists()
DirectoryDestination::getFile in lib/backup_migrate_core/src/Destination/DirectoryDestination.php
Get a file object representing the file with the given ID from the destination. This file item will not necessarily be readable nor will it have extended metadata loaded. Use loadForReading and loadFileMetadata to get those.
DirectoryDestination::loadFileForReading in lib/backup_migrate_core/src/Destination/DirectoryDestination.php
Load the file with the given ID from the destination.

File

lib/backup_migrate_core/src/Destination/DirectoryDestination.php, line 208

Class

DirectoryDestination
Class ServerDirectoryDestination.

Namespace

BackupMigrate\Core\Destination

Code

public function fileExists($id) {
  return file_exists($this
    ->_idToPath($id));
}