#include <p2pcommunicator.hh>
|
| SimpleMessageBuffer (const double factor=1.1) |
| constructor taking memory reserve estimation factor (default is 1.1, i.e. 10% over estimation ) More...
|
|
void | clear () |
| clear the buffer More...
|
|
void | resetReadPosition () |
| reset read position of buffer to beginning More...
|
|
size_t | size () const |
| return size of buffer More...
|
|
void | reserve (const size_t size) |
| reserve memory for 'size' entries
More...
|
|
void | resize (const size_t size) |
| resize buffer to 'size' entries
More...
|
|
template<class T > |
void | write (const T &value) |
| write value to buffer, value must implement the operator= correctly (i.e. no internal pointers etc.) More...
|
|
void | write (const std::string &str) |
|
template<class T > |
void | read (T &value) const |
| read value from buffer, value must implement the operator= correctly (i.e. no internal pointers etc.) More...
|
|
void | read (std::string &str) const |
|
std::pair< char *, int > | buffer () const |
| return pointer to buffer and size for use with MPI functions More...
|
|
◆ SimpleMessageBuffer()
Dune::SimpleMessageBuffer::SimpleMessageBuffer |
( |
const double |
factor = 1.1 | ) |
|
|
inline |
constructor taking memory reserve estimation factor (default is 1.1, i.e. 10% over estimation )
References resetReadPosition().
◆ buffer()
std::pair< char *, int > Dune::SimpleMessageBuffer::buffer |
( |
| ) |
const |
|
inline |
return pointer to buffer and size for use with MPI functions
◆ clear()
void Dune::SimpleMessageBuffer::clear |
( |
| ) |
|
|
inline |
◆ read() [1/2]
void Dune::SimpleMessageBuffer::read |
( |
std::string & |
str | ) |
const |
|
inline |
◆ read() [2/2]
template<class T >
void Dune::SimpleMessageBuffer::read |
( |
T & |
value | ) |
const |
|
inline |
read value from buffer, value must implement the operator= correctly (i.e. no internal pointers etc.)
Referenced by read().
◆ reserve()
void Dune::SimpleMessageBuffer::reserve |
( |
const size_t |
size | ) |
|
|
inline |
reserve memory for 'size' entries
References size().
Referenced by write().
◆ resetReadPosition()
void Dune::SimpleMessageBuffer::resetReadPosition |
( |
| ) |
|
|
inline |
◆ resize()
void Dune::SimpleMessageBuffer::resize |
( |
const size_t |
size | ) |
|
|
inline |
resize buffer to 'size' entries
References size().
◆ size()
size_t Dune::SimpleMessageBuffer::size |
( |
| ) |
const |
|
inline |
◆ write() [1/2]
void Dune::SimpleMessageBuffer::write |
( |
const std::string & |
str | ) |
|
|
inline |
◆ write() [2/2]
template<class T >
void Dune::SimpleMessageBuffer::write |
( |
const T & |
value | ) |
|
|
inline |
write value to buffer, value must implement the operator= correctly (i.e. no internal pointers etc.)
References reserve().
Referenced by write().
The documentation for this class was generated from the following file: