ZeusBase-Library
2.0.4
|
#include <IInputStream.hpp>
Public Member Functions | |
virtual bool MQUALIFIER | available () const =0 |
virtual bool MQUALIFIER | isEndReached () const =0 |
virtual Retval MQUALIFIER | read (char *pBuffer, Int iBufferSize, Int &rValidSize) const =0 |
virtual Int MQUALIFIER | readItem () const =0 |
virtual Int8 MQUALIFIER | readInt8 (bool *pError) const =0 |
virtual Int16 MQUALIFIER | readInt16 (bool *pError) const =0 |
virtual Int32 MQUALIFIER | readInt32 (bool *pError) const =0 |
virtual Int64 MQUALIFIER | readInt64 (bool *pError) const =0 |
virtual Uint8 MQUALIFIER | readUint8 (bool *pError) const =0 |
virtual Uint16 MQUALIFIER | readUint16 (bool *pError) const =0 |
virtual Uint32 MQUALIFIER | readUint32 (bool *pError) const =0 |
virtual Uint64 MQUALIFIER | readUint64 (bool *pError) const =0 |
virtual Float32 MQUALIFIER | readFloat32 (bool *pError) const =0 |
virtual Float64 MQUALIFIER | readFloat64 (bool *pError) const =0 |
virtual bool MQUALIFIER | readBool (bool *pError) const =0 |
virtual Retval MQUALIFIER | readArray (IByteArray &rData) const =0 |
virtual Retval MQUALIFIER | readString (IString &rData) const =0 |
virtual void MQUALIFIER | close ()=0 |
virtual void MQUALIFIER | reset ()=0 |
virtual bool MQUALIFIER | skip (Int iBytes=1)=0 |
Public Member Functions inherited from zeus::IZUnknown | |
virtual Retval MQUALIFIER | askForInterface (const InterfaceID &rInterfaceID, IZUnknown *&rpIface)=0 |
virtual void MQUALIFIER | addRef () const =0 |
virtual void MQUALIFIER | release () const =0 |
Interface is defining a input stream
|
pure virtual |
Returns if the input stream is available (valid).
true | : stream is ok |
false | : invalid stream |
Implemented in zeus::TSerialConnection, zeus::TAbstractInputStream, zeus::TByteArrayInputStream, zeus::TBluetoothSocket, zeus::TSocket, and zeus::TFilterInputStream.
|
pure virtual |
Closes the input stream
Implemented in zeus::TSerialConnection, zeus::TAbstractInputStream, zeus::TBluetoothSocket, zeus::TSocket, zeus::TByteArrayInputStream, zeus::TFileInputStream, and zeus::TFilterInputStream.
|
pure virtual |
This method checks if the stream is at the end. If a stream is at the end the methods readDouble(), readLong(), readByte() and readBool() should not called anymore. They will return zero. You must call this method before getting data from the stream.
true | : Stream is at the end |
false | : Stream is not at the end |
Implemented in zeus::TSerialConnection, zeus::TAbstractInputStream, zeus::TBluetoothSocket, zeus::TSocket, zeus::TByteArrayInputStream, zeus::TZippedInputStream, zeus::TFileInputStream, and zeus::TFilterInputStream.
|
pure virtual |
Reads from a stream into a buffer
pBuffer | : Char Array |
iBufferSize | : Size of the Array |
rValidSize | : Length of the read buffer (return parameter) |
RET_NOERROR | : Reading was successful |
RET_REQUEST_FAILED | : Could not read from Socket |
Implemented in zeus::TSerialConnection, zeus::TAbstractInputStream, zeus::TTextInputStream, zeus::TBluetoothSocket, zeus::TSocket, zeus::TByteArrayInputStream, zeus::TBase64InputStream, zeus::TZippedInputStream, zeus::TFileInputStream, zeus::TFilterInputStream, and zeus::TCryptedInputStream.
|
pure virtual |
Reads an array of bytes from a stream. This method uses special notation of the buffer and can only be used if the stream has written using writeArray() method. First 4 Bytes read gives the size of the following byte array to read. [4][3][2][1] = size, [0][1]..[size].
rData | : Return parameter |
RET_NOERROR | : Bytes readed |
Implemented in zeus::TSerialConnection, zeus::TAbstractInputStream, zeus::TTextInputStream, zeus::TBluetoothSocket, and zeus::TSocket.
|
pure virtual |
Reads a bool value from a stream
pError | : Error return flag. If *pError = true an error has been occured reading from the stream |
Implemented in zeus::TSerialConnection, zeus::TAbstractInputStream, zeus::TTextInputStream, zeus::TBluetoothSocket, and zeus::TSocket.
|
pure virtual |
Reads a Float32 value from a stream
pError | : Error return flag. If *pError = true an error has been occured reading from the stream |
Implemented in zeus::TSerialConnection, zeus::TAbstractInputStream, zeus::TTextInputStream, zeus::TBluetoothSocket, and zeus::TSocket.
|
pure virtual |
Reads a Float64 value from a stream
pError | : Error return flag. If *pError = true an error has been occured reading from the stream |
Implemented in zeus::TSerialConnection, zeus::TAbstractInputStream, zeus::TTextInputStream, zeus::TBluetoothSocket, and zeus::TSocket.
|
pure virtual |
Reads an int16 value from a stream
pError | : Error return flag. If *pError = true an error has been occured reading from the stream |
Implemented in zeus::TSerialConnection, zeus::TAbstractInputStream, zeus::TTextInputStream, zeus::TBluetoothSocket, and zeus::TSocket.
|
pure virtual |
Reads an int32 value from a stream
pError | : Error return flag. If *pError = true an error has been occured reading from the stream |
Implemented in zeus::TSerialConnection, zeus::TAbstractInputStream, zeus::TTextInputStream, zeus::TBluetoothSocket, and zeus::TSocket.
|
pure virtual |
Reads an int64 value from a stream
pError | : Error return flag. If *pError = true an error has been occured reading from the stream |
Implemented in zeus::TSerialConnection, zeus::TAbstractInputStream, zeus::TTextInputStream, zeus::TBluetoothSocket, and zeus::TSocket.
|
pure virtual |
Reads an int8 value from a stream
pError | : Error return flag. If *pError = true an error has been occured reading from the stream |
Implemented in zeus::TSerialConnection, zeus::TAbstractInputStream, zeus::TTextInputStream, zeus::TBluetoothSocket, and zeus::TSocket.
|
pure virtual |
Reads a single item from a stream. The size of item is 8bit large.
Implemented in zeus::TSerialConnection, zeus::TAbstractInputStream, zeus::TTextInputStream, zeus::TBluetoothSocket, zeus::TSocket, zeus::TByteArrayInputStream, zeus::TBase64InputStream, zeus::TZippedInputStream, zeus::TFileInputStream, zeus::TFilterInputStream, and zeus::TCryptedInputStream.
|
pure virtual |
Reads a string (16bit based) from the stream. This method uses spaecial notation of the buffer and can only be used if the stream has been written using writeString() method. First 4 bytes represent the size of the string. [4][3][2][1] = size, [0_h][0_l][1_h][1_l]..[size_h][size_l]. Note that this method is able to handle unicode.
rData | : Return parameter |
RET_NOERROR | : String readed |
Implemented in zeus::TSerialConnection, zeus::TAbstractInputStream, zeus::TTextInputStream, zeus::TBluetoothSocket, and zeus::TSocket.
|
pure virtual |
Reads an unsigned int16 value from a stream
pError | : Error return flag. If *pError = true an error has been occured reading from the stream |
Implemented in zeus::TSerialConnection, zeus::TAbstractInputStream, zeus::TTextInputStream, zeus::TBluetoothSocket, and zeus::TSocket.
|
pure virtual |
Reads an unsigned int32 value from a stream
pError | : Error return flag. If *pError = true an error has been occured reading from the stream |
Implemented in zeus::TSerialConnection, zeus::TAbstractInputStream, zeus::TTextInputStream, zeus::TBluetoothSocket, and zeus::TSocket.
|
pure virtual |
Reads an unsigned int64 value from a stream
pError | : Error return flag. If *pError = true an error has been occured reading from the stream |
Implemented in zeus::TSerialConnection, zeus::TAbstractInputStream, zeus::TTextInputStream, zeus::TBluetoothSocket, and zeus::TSocket.
|
pure virtual |
Reads an unsigned int8 value from a stream
pError | : Error return flag. If *pError = true an error has been occured reading from the stream |
Implemented in zeus::TSerialConnection, zeus::TAbstractInputStream, zeus::TBluetoothSocket, and zeus::TSocket.
|
pure virtual |
Sets the stream position back to the beginning
Implemented in zeus::TSerialConnection, zeus::TAbstractInputStream, zeus::TBluetoothSocket, zeus::TSocket, zeus::TByteArrayInputStream, zeus::TFileInputStream, zeus::TFilterInputStream, and zeus::TCryptedInputStream.
|
pure virtual |
This method is used to skip a number of bytes
iBytes | : Number of bytes to skip (default = 1) |
true | : Byte skipped |
false | Error or end of stream reached |
Implemented in zeus::TSerialConnection, zeus::TAbstractInputStream, zeus::TBluetoothSocket, zeus::TSocket, zeus::TByteArrayInputStream, zeus::TFileInputStream, and zeus::TFilterInputStream.