Overload of StrSplit() that takes ownership of a std::string input and filters substrings with a Predicate.

Synopsis

Declared in <absl/strings/str_split.h>

template<
    typename Delimiter,
    typename Predicate,
    typename StringType,
    EnableSplitIfString<StringType> = 0>
/* implementation-defined */::Splitter</* implementation-defined */::type, Predicate, std::string>
StrSplit(
    StringType&& text,
    Delimiter d,
    Predicate p);

Return Value

A lazy range of the retained substrings.

Parameters

Name

Description

text

The string to split; ownership is transferred to the result.

d

The delimiter identifying the split points.

p

The predicate that decides whether a substring is included.

Created with MrDocs