#include <common.h>
Public Types | |
typedef obuf_storage::buffer_type | physical_buf_t |
This is the type of the physical buffer. | |
typedef container_traits< physical_buf_t > | cont_trts |
Describes the properties of the buffer. | |
typedef cont_trts::const_iterator | const_iterator |
typedef cont_trts::iterator | iterator |
typedef cont_trts::value_type | value_type |
Public Member Functions | |
internal_buffer () | |
internal_buffer (const internal_buffer &aBuf) | |
internal_buffer (physical_buf_t &aBuf) | |
Very fast because only reference copies. | |
physical_buf_t & | phys_buf (void) |
This class can behave as a physical_buf_t due to this converter. | |
const physical_buf_t & | phys_buf (void) const |
const physical_buf_t & | phys_buf_const (void) const |
const_iterator | begin (void) const |
For read-only access. | |
const_iterator | end (void) const |
void | push_back (const value_type &aVT) |
void | resize (size_t aSz) |
Ensures that the buffer is big enough. It never shrinks a buffer. | |
bool | empty (void) const |
Tests whether the buffer is empty. | |
void | clear (void) |
Private Member Functions | |
void | check (void) const |
Runtime check for debug version. | |
internal_buffer & | operator= (const internal_buffer &aIB) |
Assignation is forbidden : Too dangerous because of the buffer pointer. | |
Private Attributes | |
physical_buf_t * | _buf |
As 'IterBuf' is not void, we use a pointer to the buffer given by IterBuf. |
typedef cont_trts::const_iterator rpa::obuf_storage< Buffer, IterBuf >::internal_buffer::const_iterator |
typedef container_traits<physical_buf_t> rpa::obuf_storage< Buffer, IterBuf >::internal_buffer::cont_trts |
Describes the properties of the buffer.
typedef cont_trts::iterator rpa::obuf_storage< Buffer, IterBuf >::internal_buffer::iterator |
typedef obuf_storage::buffer_type rpa::obuf_storage< Buffer, IterBuf >::internal_buffer::physical_buf_t |
This is the type of the physical buffer.
typedef cont_trts::value_type rpa::obuf_storage< Buffer, IterBuf >::internal_buffer::value_type |
rpa::obuf_storage< Buffer, IterBuf >::internal_buffer::internal_buffer | ( | ) | [inline] |
Simple default constructor. The pointer is intentionnaly made invalid for helping the detection of an error. For this reason only.
rpa::obuf_storage< Buffer, IterBuf >::internal_buffer::internal_buffer | ( | const internal_buffer & | aBuf | ) | [inline] |
Plain copy constructor. Note the pointer is simply copied, because the object comes from 'outside'.
rpa::obuf_storage< Buffer, IterBuf >::internal_buffer::internal_buffer | ( | physical_buf_t & | aBuf | ) | [inline] |
Very fast because only reference copies.
const_iterator rpa::obuf_storage< Buffer, IterBuf >::internal_buffer::begin | ( | void | ) | const [inline] |
For read-only access.
void rpa::obuf_storage< Buffer, IterBuf >::internal_buffer::check | ( | void | ) | const [inline, private] |
Runtime check for debug version.
void rpa::obuf_storage< Buffer, IterBuf >::internal_buffer::clear | ( | void | ) | [inline] |
The buffer is cleared before each algorithm execution. This is necessary, because obuf_iterators with infinite-size output buffers, write their output into a back_inserter. So, without a 'clear', we would keep the data of the last previous run.
bool rpa::obuf_storage< Buffer, IterBuf >::internal_buffer::empty | ( | void | ) | const [inline] |
Tests whether the buffer is empty.
const_iterator rpa::obuf_storage< Buffer, IterBuf >::internal_buffer::end | ( | void | ) | const [inline] |
internal_buffer& rpa::obuf_storage< Buffer, IterBuf >::internal_buffer::operator= | ( | const internal_buffer & | aIB | ) | [private] |
Assignation is forbidden : Too dangerous because of the buffer pointer.
const physical_buf_t& rpa::obuf_storage< Buffer, IterBuf >::internal_buffer::phys_buf | ( | void | ) | const [inline] |
The compiler can choose the const or non-const version. This is specially done for flush_all and flush_itr.
physical_buf_t& rpa::obuf_storage< Buffer, IterBuf >::internal_buffer::phys_buf | ( | void | ) | [inline] |
This class can behave as a physical_buf_t due to this converter.
const physical_buf_t& rpa::obuf_storage< Buffer, IterBuf >::internal_buffer::phys_buf_const | ( | void | ) | const [inline] |
This class can behave as a physical_buf_t due to this converter. Here, we enforce the constness, without discussion.
void rpa::obuf_storage< Buffer, IterBuf >::internal_buffer::push_back | ( | const value_type & | aVT | ) | [inline] |
If the buffer has an unlimited size. We can safely use 'push_back' of the container, because it cannot be a fixed-size C-style array.
void rpa::obuf_storage< Buffer, IterBuf >::internal_buffer::resize | ( | size_t | aSz | ) | [inline] |
Ensures that the buffer is big enough. It never shrinks a buffer.
physical_buf_t* rpa::obuf_storage< Buffer, IterBuf >::internal_buffer::_buf [private] |
As 'IterBuf' is not void, we use a pointer to the buffer given by IterBuf.