You are here

public function WritableStreamBackupFile::writeAll in Backup and Migrate 8.4

A shorthand function to open the file, write the given contents and close the file. Used for small amounts of data that can fit in memory.

Parameters

$data:

Overrides BackupFileWritableInterface::writeAll

File

lib/backup_migrate_core/src/File/WritableStreamBackupFile.php, line 101

Class

WritableStreamBackupFile
Class TempFile.

Namespace

BackupMigrate\Core\File

Code

public function writeAll($data) {
  $this
    ->openForWrite();
  $this
    ->write($data);
  $this
    ->close();
}