- \PHPUnit_Util_Printer
class (none) \ PHPUnit_Util_Printer
- All known direct subclasses:
- PHPUnit_TextUI_ResultPrinter, PHPUnit_Util_Log_JSON, PHPUnit_Util_Log_JUnit, PHPUnit_Util_Log_TAP, PHPUnit_Util_TestDox_ResultPrinter
Utility class that can print to STDOUT or write to a file.
Method Summary
Name | Description |
---|---|
__construct($out = null) | Constructor. |
flush() | Flush buffer, optionally tidy up HTML, and close output if it's not to a php stream |
getAutoFlush() | Check auto-flush mode. |
incrementalFlush() | Performs a safe, incremental flush. |
setAutoFlush($autoFlush) | Set auto-flushing mode. |
write($buffer) |
public function __construct($out = null)
Constructor.
- Parameters:
mixed
- $out- Defaults:
out
=null
- Throws:
- PHPUnit_Framework_Exception
public function flush()
Flush buffer, optionally tidy up HTML, and close output if it's not to a php stream
public function getAutoFlush()
Check auto-flush mode.
- Returns:
- boolean
public function 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.
public function setAutoFlush($autoFlush)
Set auto-flushing mode.
If set, *incremental* flushes will be done after each write. This should not be confused with the different effects of this class' flush() method.
- Parameters:
boolean
- $autoFlush
public function write($buffer)
- Parameters:
string
- $buffer