Public Member Functions

# wxBufferedInputStream Class Reference
[Streams]

`#include <wx/stream.h>`

Inheritance diagram for wxBufferedInputStream:
[legend]

## Detailed Description

This stream acts as a cache.

It caches the bytes read from the specified input stream (see wxFilterInputStream). It uses wxStreamBuffer and sets the default in-buffer size to 1024 bytes. This class may not be used without some other stream to read the data from (such as a file stream or a memory stream).

##

Library: wxBase
Category: Streams

See also:
  wxStreamBuffer, wxInputStream, wxBufferedOutputStream

## Public Member Functions
| wxBufferedInputStream (wxInputStream &stream, wxStreamBuffer *buffer=NULL)
| Constructor using the provided buffer or default.
| wxBufferedInputStream (wxInputStream &stream, size_t bufsize)
| Constructor allowing to specify the size of the buffer.
virtual | ~wxBufferedInputStream ()
| Destructor.

List of all members.

## Constructor & Destructor Documentation

wxBufferedInputStream::wxBufferedInputStream | ( | wxInputStream & | stream,
|  | wxStreamBuffer * | buffer = `NULL` |
| ) |  |  |

Constructor using the provided buffer or default.

Parameters:

  | stream | The associated low-level stream.
  | buffer | The buffer to use if non-NULL. Notice that the ownership of this buffer is taken by the stream, i.e. it will delete it. If this parameter is NULL a default 1KB buffer is used.

wxBufferedInputStream::wxBufferedInputStream | ( | wxInputStream & | stream,
|  | size_t | bufsize |
| ) |  |  |

Constructor allowing to specify the size of the buffer.

This is just a more convenient alternative to creating a wxStreamBuffer of the given size and using the other overloaded constructor of this class.

Parameters:

  | stream | The associated low-level stream.
  | bufsize | The size of the buffer, in bytes.

Since:
  2.9.0

virtual wxBufferedInputStream::~wxBufferedInputStream | ( |  | ) | `[virtual]`

Destructor.

|  | [ top ]