JugiMap Framework
|
Extended BinaryStreamReader class which reads from a memory buffer. More...
#include <jmStreams.h>
Inherits BinaryStreamReader.
Inherited by BinaryFileStreamReaderCC.
Public Member Functions | |
BinaryBufferStreamReader (unsigned char *_buff, int _size, bool _ownedBuffer) | |
Constructor. More... | |
bool | IsOpen () override |
Returns true if the stream of this object is open for reading; if not it returns false. More... | |
int | Pos () override |
Returns the current reading position of the stream. More... | |
void | Seek (int _pos) override |
Set the current reading position of the stream. More... | |
int | Size () override |
Returns the size of the stream. More... | |
void | Close () override |
Close the stream. More... | |
unsigned char | ReadByte () override |
Read and returns the byte number. More... | |
int | ReadInt () override |
Read and returns the integer number (4 bytes). More... | |
float | ReadFloat () override |
Read and returns the float number (4 bytes). More... | |
std::string | ReadString () override |
Read and returns the string. The length of string is written as the integer at the start. More... | |
![]() | |
virtual | ~BinaryStreamReader () |
Destructor. More... | |
Extended BinaryStreamReader class which reads from a memory buffer.
|
inline |
Constructor.
Creates a new BinaryBufferStreamReader object with the given memory buffer *_buff* of the size *_size*. If parameter *_ownedBuffer* is true the reader takes ownership of the buffer and will delete it on destruction.
|
inlineoverridevirtual |
Returns true if the stream of this object is open for reading; if not it returns false.
Implements BinaryStreamReader.
|
inlineoverridevirtual |
Returns the current reading position of the stream.
Implements BinaryStreamReader.
|
inlineoverridevirtual |
Set the current reading position of the stream.
Implements BinaryStreamReader.
|
inlineoverridevirtual |
Returns the size of the stream.
Implements BinaryStreamReader.
|
inlineoverridevirtual |
Close the stream.
Implements BinaryStreamReader.
|
inlineoverridevirtual |
Read and returns the byte number.
Implements BinaryStreamReader.
|
inlineoverridevirtual |
Read and returns the integer number (4 bytes).
Implements BinaryStreamReader.
|
inlineoverridevirtual |
Read and returns the float number (4 bytes).
Implements BinaryStreamReader.
|
inlineoverridevirtual |
Read and returns the string. The length of string is written as the integer at the start.
Implements BinaryStreamReader.