MCPcopy Create free account
hub / github.com/boostorg/asio / basic_streambuf

Method basic_streambuf

include/boost/asio/basic_streambuf.hpp:133–143  ·  view source on GitHub ↗

Construct a basic_streambuf object. * Constructs a streambuf with the specified maximum size. The initial size * of the streambuf's input sequence is 0. */

Source from the content-addressed store, hash-verified

131 * of the streambuf's input sequence is 0.
132 */
133 explicit basic_streambuf(
134 std::size_t maximum_size = (std::numeric_limits<std::size_t>::max)(),
135 const Allocator& allocator = Allocator())
136 : max_size_(maximum_size),
137 buffer_(allocator)
138 {
139 std::size_t pend = (std::min<std::size_t>)(max_size_, buffer_delta);
140 buffer_.resize((std::max<std::size_t>)(pend, 1));
141 setg(&buffer_[0], &buffer_[0], &buffer_[0]);
142 setp(&buffer_[0], &buffer_[0] + pend);
143 }
144
145 /// Get the size of the input sequence.
146 /**

Callers

nothing calls this directly

Calls 1

resizeMethod · 0.45

Tested by

no test coverage detected