Contents Up Previous Next

wxInputStream

Derived from

wxStreamBase

Include files

<wx/stream.h>

See also

wxStreamBuffer

wxInputStream::wxInputStream
wxInputStream::~wxInputStream
wxInputStream::GetC
wxInputStream::InputStreamBuffer
wxInputStream::LastRead
wxInputStream::Peek
wxInputStream::Read
wxInputStream::SeekI
wxInputStream::TellI


wxInputStream::wxInputStream

wxInputStream()

Creates a dummy input stream.

wxInputStream(wxStreamBuffer *sbuf)

Creates an input stream using the specified stream buffer sbuf. This stream buffer can point to another stream.


wxInputStream::~wxInputStream

~wxInputStream()

Destructor.


wxInputStream::GetC

char GetC()

Returns the first character in the input queue and removes it.


wxInputStream::InputStreamBuffer

wxStreamBuffer* InputStreamBuffer()

Returns the stream buffer associated with the input stream.


wxInputStream::LastRead

size_t LastRead() const

Returns the last number of bytes read.


wxInputStream::Peek

char Peek()

Returns the first character in the input queue without removing it.


wxInputStream::Read

wxInputStream& Read(void *buffer, size_t size)

Reads the specified amount of bytes and stores the data in buffer.

Warning

The buffer absolutely needs to have at least the specified size.

Return value

This function returns a reference on the current object, so the user can test any states of the stream right away.

wxInputStream& Read(wxOutputStream& stream_out)

Reads data from the input queue and stores it in the specified output stream. The data is read until an error is raised by one of the two streams.

Return value

This function returns a reference on the current object, so the user can test any states of the stream right away.


wxInputStream::SeekI

off_t SeekI(off_t pos, wxSeekMode mode = wxFromStart)

Changes the stream current position.


wxInputStream::TellI

off_t TellI() const

Returns the current stream position.