public function PHPUnit_Util_Printer::incrementalFlush

Performs a safe, incremental flush.

Do not confuse this function with the flush() function of this class, since the flush() function may close the file being written to, rendering the current object no longer usable.

@since Method available since Release 3.3.0

1 call to PHPUnit_Util_Printer::incrementalFlush()
PHPUnit_Util_Printer::write in drupal/core/vendor/phpunit/phpunit/PHPUnit/Util/Printer.php

File

drupal/core/vendor/phpunit/phpunit/PHPUnit/Util/Printer.php, line 147

Class

PHPUnit_Util_Printer
Utility class that can print to STDOUT or write to a file.

Code

public function incrementalFlush() {
  if ($this->out) {
    fflush($this->out);
  }
  else {
    flush();
  }
}