7 #include <packager/utils/string_trim_split.h>
9 #include <absl/strings/str_split.h>
12 std::vector<std::string> SplitAndTrimSkipEmpty(
const std::string& str,
14 auto tokens = absl::StrSplit(str, delimiter, absl::SkipEmpty());
15 std::vector<std::string> results;
16 for (
const absl::string_view& token : tokens) {
17 std::string trimmed = std::string(token);
18 absl::StripAsciiWhitespace(&trimmed);
19 if (!trimmed.empty()) {
20 results.push_back(trimmed);
All the methods that are virtual are virtual for mocking.