|
Loading...
Searching...
No Matches
#include <core.h>
template<typename T>
class detail::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
Definition at line 665 of file core.h.
◆ const_reference
◆ value_type
◆ buffer() [1/3]
◆ buffer() [2/3]
template<typename T >
buffer |
( |
T * | p = nullptr, |
|
|
size_t | sz = 0, |
|
|
size_t | cap = 0 ) |
|
protected |
◆ ~buffer()
◆ buffer() [3/3]
◆ append()
template<typename T >
template<typename U >
void append |
( |
const U * | begin, |
|
|
const U * | end ) |
◆ begin() [1/2]
template<typename T >
const T * begin |
( |
| ) |
const |
◆ begin() [2/2]
◆ capacity()
template<typename T >
size_t capacity |
( |
| ) |
const |
Returns the capacity of this buffer.
Definition at line 709 of file core.h.
References buffer< T >::capacity_.
Referenced by basic_memory_buffer< T, SIZE, Allocator >::deallocate(), formatter< std::tm, Char >::format(), iterator_buffer< std::back_insert_iterator< Container >, enable_if_t< is_contiguous< Container >::value, typename Container::value_type > >::grow(), basic_memory_buffer< T, SIZE, Allocator >::move(), detail::snprintf_float(), detail::to_pointer(), and bigint::~bigint().
◆ clear()
◆ data() [1/2]
◆ data() [2/2]
Returns a pointer to the buffer data.
Definition at line 712 of file core.h.
References buffer< T >::ptr_.
Referenced by bigint::align(), bigint::assign(), basic_memory_buffer< T, SIZE, Allocator >::deallocate(), detail::fallback_format(), fallback_formatter< T, Char, enable_if_t< is_streamable< T, Char >::value > >::format(), formatter< std::chrono::duration< Rep, Period >, Char >::format(), detail::format_float(), basic_memory_buffer< T, SIZE, Allocator >::move(), int_writer< OutputIt, Char, UInt >::on_num(), detail::report_error(), detail::snprintf_float(), detail::to_pointer(), to_string(), vfprintf(), vprint(), vprint(), vprint(), and detail::write_buffer().
◆ end() [1/2]
◆ end() [2/2]
◆ grow()
template<typename T >
virtual void grow |
( |
size_t | capacity | ) |
|
|
protectedpure virtual |
Increases the buffer capacity to hold at least capacity elements.
Implemented in basic_memory_buffer< T, SIZE, Allocator >, basic_memory_buffer< bigit, bigits_capacity >, basic_memory_buffer< Char >, basic_memory_buffer< wchar_t >, counting_buffer< T >, iterator_buffer< OutputIt, T, Traits >, iterator_buffer< std::back_insert_iterator< Container >, enable_if_t< is_contiguous< Container >::value, typename Container::value_type > >, and iterator_buffer< T *, T >.
Referenced by buffer< T >::try_reserve().
◆ operator=()
template<typename T >
void operator= |
( |
const buffer< T > & | | ) |
|
|
delete |
◆ operator[]() [1/2]
template<typename T >
template<typename I >
T & operator[] |
( |
I | index | ) |
|
◆ operator[]() [2/2]
template<typename T >
template<typename I >
const T & operator[] |
( |
I | index | ) |
const |
◆ push_back()
template<typename T >
void push_back |
( |
const T & | value | ) |
|
◆ set()
template<typename T >
void set |
( |
T * | buf_data, |
|
|
size_t | buf_capacity ) |
|
protected |
◆ size()
Returns the size of this buffer.
Definition at line 706 of file core.h.
References buffer< T >::size_.
Referenced by bigint::align(), bigint::assign(), iterator_buffer< OutputIt, T, Traits >::count(), bigint::divmod_assign(), fallback_formatter< T, Char, enable_if_t< is_streamable< T, Char >::value > >::format(), formatter< detail::bigint >::format(), formatter< std::chrono::duration< Rep, Period >, Char >::format(), formatter< std::tm, Char >::format(), detail::format_float(), format_system_error(), detail::format_value(), iterator_buffer< OutputIt, T, Traits >::grow(), basic_memory_buffer< T, SIZE, Allocator >::move(), bigint::multiply(), bigint::multiply(), bigint::num_bigits(), bigint::operator<<=(), bigint::remove_leading_zeros(), detail::report_error(), detail::reserve(), utf8_to_utf16::size(), detail::snprintf_float(), bigint::square(), bigint::subtract_aligned(), detail::to_pointer(), to_string(), vfprintf(), vfprintf(), vprint(), and detail::write_buffer().
◆ try_reserve()
template<typename T >
void try_reserve |
( |
size_t | new_capacity | ) |
|
◆ try_resize()
template<typename T >
void try_resize |
( |
size_t | count | ) |
|
Definition at line 722 of file core.h.
References buffer< T >::capacity_, detail::count(), buffer< T >::size_, and buffer< T >::try_reserve().
Referenced by detail::fallback_format(), detail::format_float(), detail::format_value(), basic_memory_buffer< T, SIZE, Allocator >::resize(), detail::snprintf_float(), and detail::to_pointer().
◆ capacity_
◆ ptr_
◆ size_
|