You are here

public function ReadableStreamBackupFile::readAll in Backup and Migrate 8.4

Read a line from the file.

Return value

string The data read from the file or NULL if the file can't be read.

Overrides BackupFileReadableInterface::readAll

File

lib/backup_migrate_core/src/File/ReadableStreamBackupFile.php, line 152

Class

ReadableStreamBackupFile
Class ReadableStreamBackupFile.

Namespace

BackupMigrate\Core\File

Code

public function readAll() {
  if (!$this
    ->isOpen()) {
    $this
      ->openForRead();
  }
  $this
    ->rewind();
  return stream_get_contents($this->handle);
}