10 #ifndef BOOST_BEAST_FLAT_STATIC_BUFFER_HPP 11 #define BOOST_BEAST_FLAT_STATIC_BUFFER_HPP 14 #include <boost/asio/buffer.hpp> 87 return dist(begin_, end_);
127 out_ += std::min<std::size_t>(n, last_ - out_);
158 reset(
void* p, std::size_t n);
164 dist(
char const* first,
char const* last)
166 return static_cast<std::size_t
>(last - first);
169 template<
class =
void>
173 template<
class =
void>
175 reset_impl(
void* p, std::size_t n);
177 template<
class =
void>
179 prepare_impl(std::size_t n);
181 template<
class =
void>
183 consume_impl(std::size_t n);
202 template<std::
size_t N>
235 std::size_t constexpr
242 std::size_t constexpr
Definition: async_result.hpp:20
boost::asio::mutable_buffers_1 mutable_buffers_type
Definition: flat_static_buffer.hpp:61
flat_static_buffer_base()=default
flat_static_buffer_base const & base() const
Returns the flat_static_buffer_base portion of this object.
Definition: flat_static_buffer.hpp:229
mutable_buffers_type prepare(std::size_t n)
Definition: flat_static_buffer.ipp:49
boost::asio::mutable_buffers_1 const_buffers_type
Definition: flat_static_buffer.hpp:55
std::size_t constexpr capacity() const
Return the maximum sum of input and output sizes that can be held without an allocation.
Definition: flat_static_buffer.hpp:243
std::size_t size() const
Return the size of the input sequence.
Definition: flat_static_buffer.hpp:78
flat_static_buffer_base & base()
Returns the flat_static_buffer_base portion of this object.
Definition: flat_static_buffer.hpp:222
std::size_t capacity() const
Return the maximum sum of input and output sizes that can be held without an allocation.
Definition: flat_static_buffer.hpp:92
void consume(std::size_t n)
Remove bytes from the input sequence.
Definition: flat_static_buffer.hpp:132
void commit(std::size_t n)
Definition: flat_static_buffer.hpp:125
flat_static_buffer()
Constructor.
Definition: flat_static_buffer.hpp:212
std::size_t constexpr max_size() const
Return the maximum sum of the input and output sequence sizes.
Definition: flat_static_buffer.hpp:236
const_buffers_type data() const
Definition: flat_static_buffer.ipp:32
Definition: flat_static_buffer.hpp:203
Definition: flat_static_buffer.hpp:39
std::size_t max_size() const
Return the maximum sum of the input and output sequence sizes.
Definition: flat_static_buffer.hpp:85
flat_static_buffer_base(void *p, std::size_t n)
Definition: flat_static_buffer.hpp:71
void reset()
Set the input and output sequences to size 0.
Definition: flat_static_buffer.ipp:41