A line extracted from a circular read buffer, represented in up to two parts. More...
#include <sockutils.hpp>
Public Member Functions | |
| size_t | Size () const |
| operator bool () const | |
Public Attributes | |
| std::string_view | Part1 |
| First (or only) segment of the line. | |
| std::string_view | Part2 |
| Continuation segment if the line wraps; empty otherwise. | |
A line extracted from a circular read buffer, represented in up to two parts.
Because the underlying buffer is circular, a single logical line may wrap around the buffer boundary. Part1 is the first segment, Part2 (possibly empty) is the continuation from the start of the buffer. Size() returns the total byte count.
operator bool() returns false when Part1 is empty (no complete line yet).
The string views are valid only until the next Push/Acquire/Commit call on the owning TLineSplitter or TZeroCopyLineSplitter.