A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://wxpython.org/Phoenix/docs/html/wx.StreamBase.html below:

wx.StreamBase — wxPython Phoenix 4.2.4a1 documentation

wx.StreamBase¶

This class is the base class of most stream related classes in wxWidgets.

It must not be used directly.

Class Hierarchy¶

Inheritance diagram for class

StreamBase

:

Known Subclasses¶

wx.InputStream, wx.OutputStream

Methods Summary¶

__init__

Creates a dummy stream object.

GetLastError

This function returns the last error.

GetLength

Returns the length of the stream in bytes.

GetSize

This function returns the size of the stream.

IsOk

Returns True if no error occurred on the stream.

IsSeekable

Returns True if the stream supports seeking to arbitrary offsets.

Reset

Resets the stream state.

Properties Summary¶ Class API¶
class wx.StreamBase(object)¶

Possible constructors:

This class is the base class of most stream related classes in wxWidgets.


Methods¶
__init__(self)¶

Creates a dummy stream object.

It doesn’t do anything.

Return type:

None


GetLastError(self)¶

This function returns the last error.

Return type:

wx.StreamError


GetLength(self)¶

Returns the length of the stream in bytes.

If the length cannot be determined (this is always the case for socket streams for example), returns InvalidOffset .

Return type:

wx.FileOffset

Added in version 2.5.4.


GetSize(self)¶

This function returns the size of the stream.

For example, for a file it is the size of the file.

Return type:

int

Warning

There are streams which do not have size by definition, such as socket streams. In that cases, GetSize returns 0 so you should always test its return value.


IsOk(self)¶

Returns True if no error occurred on the stream.

Return type:

bool


IsSeekable(self)¶

Returns True if the stream supports seeking to arbitrary offsets.

Return type:

bool


Reset(self, error=STREAM_NO_ERROR)¶

Resets the stream state.

By default, resets the stream to good state, i.e. clears any errors. Since wxWidgets 2.9.3 can be also used to explicitly set the state to the specified error (the error argument didn’t exist in the previous versions).

Parameters:

error (StreamError)

Return type:

None


Properties¶
LastError¶

See GetLastError


Length¶

See GetLength


Size¶

See GetSize


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4