Loading...
Searching...
No Matches
Dune::SimpleMessageBuffer Class Reference

## Public Member Functions

| SimpleMessageBuffer (const double factor=1.1)
| constructor taking memory reserve estimation factor (default is 1.1, i.e.
void | clear ()
| clear the buffer
void | resetReadPosition ()
| reset read position of buffer to beginning
size_t | size () const
| return size of buffer
void | reserve (const size_t size)
| reserve memory for 'size' entries
void | resize (const size_t size)
| resize buffer to 'size' entries
template<class T>
void | write (const T &value)
| write value to buffer, value must implement the operator= correctly (i.e.
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.
void | read (std::string &str) const
std::pair< char *, int > | buffer () const
| return pointer to buffer and size for use with MPI functions

## Constructor & Destructor Documentation

## SimpleMessageBuffer()

Dune::SimpleMessageBuffer::SimpleMessageBuffer | ( | const double | factor = 1.1 | ) |

inline explicit

constructor taking memory reserve estimation factor (default is 1.1, i.e.

10% over estimation )

## Member Function Documentation

## read()

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.)

## write()

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.)

The documentation for this class was generated from the following file:

- opm/grid/common/p2pcommunicator.hh