#include <core.h>
Inherited by iterator_buffer< OutputIt, T, Traits >, and iterator_buffer< T *, T >.
|
| auto | size () const FMT_NOEXCEPT -> size_t |
| |
| auto | capacity () const FMT_NOEXCEPT -> size_t |
| |
| auto | data () FMT_NOEXCEPT -> T * |
| |
| auto | data () const FMT_NOEXCEPT -> const T * |
| |
| void | clear () |
| |
| template<typename U > |
| void | append (const U *begin, const U *end) |
| |
|
| void | set (T *buf_data, size_t buf_capacity) FMT_NOEXCEPT |
| |
| virtual void | grow (size_t capacity)=0 |
| |
template<typename T>
class buffer< T >
\rst A contiguous memory buffer with an optional growing ability. It is an internal class and shouldn't be used directly, only via ~fmtbasic_memory_buffer. \endrst
◆ append()
template<typename T >
template<typename U >
| void buffer< T >::append |
( |
const U * |
begin, |
|
|
const U * |
end |
|
) |
| |
Appends data to the end of the buffer.
◆ capacity()
template<typename T >
| auto buffer< T >::capacity |
( |
| ) |
const -> size_t |
|
inline |
Returns the capacity of this buffer.
◆ clear()
◆ data() [1/2]
template<typename T >
| auto buffer< T >::data |
( |
| ) |
const -> const T* |
|
inline |
Returns a pointer to the buffer data.
◆ data() [2/2]
template<typename T >
| auto buffer< T >::data |
( |
| ) |
-> T* |
|
inline |
Returns a pointer to the buffer data.
◆ grow()
template<typename T >
| virtual void buffer< T >::grow |
( |
size_t |
capacity | ) |
|
|
protectedpure virtual |
Increases the buffer capacity to hold at least capacity elements.
◆ set()
template<typename T >
| void buffer< T >::set |
( |
T * |
buf_data, |
|
|
size_t |
buf_capacity |
|
) |
| |
|
inlineprotected |
Sets the buffer data and capacity.
◆ size()
template<typename T >
| auto buffer< T >::size |
( |
| ) |
const -> size_t |
|
inline |
Returns the size of this buffer.