27 const std::string_view
message) {
28 std::vector<std::string>
strings;
31 std::string_view remainder =
message;
32 for (std::size_t
end = 0;
end = remainder.find(
'\n'),
end != remainder.npos;
33 remainder = remainder.substr(
end + 1)) {
34 const auto line = remainder.substr(0,
end);
35 if (!unfinished_line_.empty()) {
36 std::string new_message = std::move(unfinished_line_);
37 unfinished_line_.clear();
39 strings.push_back(std::move(new_message));
48 unfinished_line_ += remainder;
54 if (unfinished_line_.empty()) {
58 std::vector<std::string>
strings = {std::move(unfinished_line_)};
59 unfinished_line_.clear();
std::vector< std::string > Flush()
std::vector< std::string > Parse(std::string_view message)
Collection of objects used to extend the Constraint Solver library.
std::optional< int64_t > end