Overview

Namespaces

  • Webmozart
    • Console
      • Adapter
      • Api
        • Application
        • Args
          • Format
        • Command
        • Config
        • Event
        • Formatter
        • IO
        • Resolver
      • Args
      • Config
      • Formatter
      • Handler
        • Help
      • IO
        • InputStream
        • OutputStream
      • Process
      • Resolver
      • UI
        • Alignment
        • Component
        • Help
        • Layout
        • Style
      • Util

Classes

  • BufferedOutputStream
  • ErrorOutputStream
  • NullOutputStream
  • StandardOutputStream
  • StreamOutputStream
  • Overview
  • Namespace
  • Class

Class BufferedOutputStream

An output stream that writes to a buffer.

Webmozart\Console\IO\OutputStream\BufferedOutputStream implements Webmozart\Console\Api\IO\OutputStream
Namespace: Webmozart\Console\IO\OutputStream
Author: Bernhard Schussek bschussek@gmail.com
Since: 1.0
Located at IO/OutputStream/BufferedOutputStream.php
Methods summary
public string
# fetch( )

Returns the contents of the buffer.

Returns the contents of the buffer.

Returns

string
The buffered data.
public
# clear( )

Clears the buffer.

Clears the buffer.

public
# write( string $string )

Writes a string to the stream.

Writes a string to the stream.

Parameters

$string
The string to write.

Throws

Webmozart\Console\Api\IO\IOException
If writing fails or if the stream is closed.

Implementation of

Webmozart\Console\Api\IO\OutputStream::write()
public
# flush( )

Flushes the stream and forces all pending text to be written out.

Flushes the stream and forces all pending text to be written out.

Throws

Webmozart\Console\Api\IO\IOException
If flushing fails or if the stream is closed.

Implementation of

Webmozart\Console\Api\IO\OutputStream::flush()
public boolean
# supportsAnsi( )

Returns whether the stream supports ANSI format codes.

Returns whether the stream supports ANSI format codes.

Returns

boolean

Returns true if the stream supports ANSI format codes and false otherwise.

Implementation of

Webmozart\Console\Api\IO\OutputStream::supportsAnsi()
public
# close( )

Closes the stream.

Closes the stream.

Implementation of

Webmozart\Console\Api\IO\OutputStream::close()
public boolean
# isClosed( )

Returns whether the stream is closed.

Returns whether the stream is closed.

Returns

boolean
Returns true if the stream is closed.

Implementation of

Webmozart\Console\Api\IO\OutputStream::isClosed()
Webmozart Console API API documentation generated by ApiGen