#include <dataIStream.h>

Public Member Functions | |
Internal | |
| DataIStream () | |
| virtual | ~DataIStream () |
| virtual size_t | nRemainingBuffers () const =0 |
| Get the number of remaining buffers. | |
| virtual uint32_t | getVersion () const |
| virtual void | reset () |
Data input | |
| template<typename T > | |
| DataIStream & | operator>> (T &value) |
| Read a plain data item. | |
| template<typename T > | |
| DataIStream & | operator>> (std::vector< T > &value) |
| Read a std::vector of serializable items. | |
| void | read (void *data, uint64_t size) |
| Read a number of bytes from the stream into a buffer. | |
| const void * | getRemainingBuffer () |
| Get the pointer to the remaining data in the current buffer. | |
| uint64_t | getRemainingBufferSize () |
| Get the size of the remaining data in the current buffer. | |
| void | advanceBuffer (const uint64_t offset) |
| Advance the current buffer by a number of bytes. | |
Specialized input operators | |
| template<> | |
| DataIStream & | operator>> (std::string &str) |
| Read a std::string. | |
| template<> | |
| DataIStream & | operator>> (base::UUID &id) |
| Read a base::UUID. | |
| template<> | |
| DataIStream & | operator>> (std::vector< uint8_t > &value) |
| Optimized specialization to read a std::vector of uint8_t. | |
| template<> | |
| DataIStream & | operator>> (std::vector< uint32_t > &value) |
| Optimized specialization to read a std::vector of uint32_t. | |
| template<> | |
| DataIStream & | operator>> (std::vector< int32_t > &value) |
| Optimized specialization to read a std::vector of int32_t. | |
| template<> | |
| DataIStream & | operator>> (std::vector< uint64_t > &value) |
| Optimized specialization to read a std::vector of uint64_t. | |
| template<> | |
| DataIStream & | operator>> (std::vector< int64_t > &value) |
| Optimized specialization to read a std::vector of int64_t. | |
| template<> | |
| DataIStream & | operator>> (std::vector< float > &value) |
| Optimized specialization to read a std::vector of float. | |
| template<> | |
| DataIStream & | operator>> (std::vector< double > &value) |
| Optimized specialization to read a std::vector of double. | |
Protected Member Functions | |
| virtual bool | getNextBuffer (const uint8_t **buffer, uint64_t *size)=0 |
Definition at line 33 of file dataIStream.h.
| virtual size_t eq::net::DataIStream::nRemainingBuffers | ( | ) | const [pure virtual] |
| DataIStream& eq::net::DataIStream::operator>> | ( | T & | value | ) | [inline] |
Read a plain data item.
Definition at line 53 of file dataIStream.h.
References read().

| DataIStream& eq::net::DataIStream::operator>> | ( | std::vector< T > & | value | ) | [inline] |
Read a std::vector of serializable items.
Definition at line 58 of file dataIStream.h.
References read().

| void eq::net::DataIStream::read | ( | void * | data, | |
| uint64_t | size | |||
| ) |
Read a number of bytes from the stream into a buffer.
Definition at line 49 of file dataIStream.cpp.
References EQERROR.
Referenced by operator>>().

| const void * eq::net::DataIStream::getRemainingBuffer | ( | ) |
Get the pointer to the remaining data in the current buffer.
The data written by the DataOStream on the other end is bucketized, that is, it is sent in multiple blocks. The remaining buffer and its size points into one of the buffers, that is, not all the data sent is returned by this function. However, a write operation on the other end is never segmented, that is, if the application writes n bytes to the DataOStream, a symmetric read from the DataIStream has at least n bytes available.
Definition at line 73 of file dataIStream.cpp.
Referenced by operator>>().

| uint64_t eq::net::DataIStream::getRemainingBufferSize | ( | ) |
Get the size of the remaining data in the current buffer.
Definition at line 81 of file dataIStream.cpp.
Referenced by eq::net::FullSlaveCM::_unpackOneVersion(), and operator>>().

| void eq::net::DataIStream::advanceBuffer | ( | const uint64_t | offset | ) |
Advance the current buffer by a number of bytes.
Definition at line 89 of file dataIStream.cpp.
Referenced by operator>>().

| DataIStream& eq::net::DataIStream::operator>> | ( | std::string & | str | ) | [inline] |
Read a std::string.
Definition at line 132 of file dataIStream.h.
References advanceBuffer(), getRemainingBuffer(), getRemainingBufferSize(), and read().

| DataIStream& eq::net::DataIStream::operator>> | ( | std::vector< uint8_t > & | value | ) | [inline] |
Optimized specialization to read a std::vector of uint8_t.
Definition at line 159 of file dataIStream.h.
| DataIStream& eq::net::DataIStream::operator>> | ( | std::vector< uint32_t > & | value | ) | [inline] |
Optimized specialization to read a std::vector of uint32_t.
Definition at line 166 of file dataIStream.h.
| DataIStream& eq::net::DataIStream::operator>> | ( | std::vector< int32_t > & | value | ) | [inline] |
Optimized specialization to read a std::vector of int32_t.
Definition at line 173 of file dataIStream.h.
| DataIStream& eq::net::DataIStream::operator>> | ( | std::vector< uint64_t > & | value | ) | [inline] |
Optimized specialization to read a std::vector of uint64_t.
Definition at line 180 of file dataIStream.h.
| DataIStream& eq::net::DataIStream::operator>> | ( | std::vector< int64_t > & | value | ) | [inline] |
Optimized specialization to read a std::vector of int64_t.
Definition at line 187 of file dataIStream.h.
| DataIStream& eq::net::DataIStream::operator>> | ( | std::vector< float > & | value | ) | [inline] |
Optimized specialization to read a std::vector of float.
Definition at line 194 of file dataIStream.h.
| DataIStream& eq::net::DataIStream::operator>> | ( | std::vector< double > & | value | ) | [inline] |
Optimized specialization to read a std::vector of double.
Definition at line 201 of file dataIStream.h.
0.9 by
1.5.8