62 constexpr const char *
data()
const;
65 operator std::string()
const;
66 constexpr operator std::string_view()
const;
68 constexpr const char *
begin()
const;
69 constexpr const char *
end()
const;
75 template<
size_t N>
void copy(
char (&dst)[
N])
const;
81 constexpr const char &
front()
const;
82 constexpr const char &
back()
const;
120 constexpr const char *
c_str()
const;
134 constexpr StringRef(
const char *
begin,
const char *one_after_end);
135 constexpr StringRef(std::string_view view);
150 : data_(data), size_(size)
184inline StringRefBase::operator std::string()
const
186 return std::string(data_,
size_t(size_));
189constexpr StringRefBase::operator std::string_view()
const
191 return std::string_view(data_,
size_t(size_));
228 if (
size_ < dst_size) {
288 const int64_t substr_size = std::min(max_size,
size_ - start);
313 if (index == std::string_view::npos) {
393 return this->
trim(
" \t\r\n");
419 "forward search found characters-to-not-remove, but backward search did not");
420 const int64_t substr_len = find_end - find_front + 1;
421 return this->
substr(find_front, substr_len);
536 const int64_t new_size = std::max<int64_t>(0,
size_ - n);
589 return std::string(a) + std::string(
b);
601 return std::string_view(a) == std::string_view(
b);
606 return std::string_view(a) != std::string_view(
b);
611 return std::string_view(a) < std::string_view(
b);
616 return std::string_view(a) > std::string_view(
b);
621 return std::string_view(a) <= std::string_view(
b);
626 return std::string_view(a) >= std::string_view(
b);
#define BLI_assert_msg(a, msg)
constexpr const char & front() const
void unsafe_copy(char *dst) const
static constexpr int64_t not_found
constexpr int64_t rfind(char c, int64_t pos=INT64_MAX) const
constexpr int64_t find_last_of(StringRef chars, int64_t pos=INT64_MAX) const
void copy(char *dst, int64_t dst_size) const
constexpr int64_t find(char c, int64_t pos=0) const
constexpr const char * begin() const
constexpr const char * end() const
constexpr int64_t find_last_not_of(StringRef chars, int64_t pos=INT64_MAX) const
constexpr int64_t find_first_not_of(StringRef chars, int64_t pos=0) const
constexpr bool is_empty() const
constexpr StringRef substr(int64_t start, int64_t size) const
constexpr StringRefBase(const char *data, int64_t size)
constexpr bool startswith(StringRef prefix) const
constexpr bool endswith(StringRef suffix) const
constexpr int64_t find_first_of(StringRef chars, int64_t pos=0) const
constexpr IndexRange index_range() const
constexpr int64_t size() const
constexpr StringRef trim() const
constexpr const char * data() const
constexpr const char & back() const
constexpr const char * c_str() const
constexpr StringRefNull()
constexpr char operator[](int64_t index) const
constexpr StringRef drop_prefix(int64_t n) const
constexpr StringRef drop_suffix(int64_t n) const
constexpr char operator[](int64_t index) const
constexpr StringRef drop_known_prefix(StringRef prefix) const
local_group_size(16, 16) .push_constant(Type b
constexpr bool operator!=(StringRef a, StringRef b)
constexpr int64_t index_or_npos_to_int64(size_t index)
constexpr bool operator==(StringRef a, StringRef b)
std::string_view format_as(StringRef str)
std::ostream & operator<<(std::ostream &stream, const eAlpha &space)
constexpr bool operator>=(StringRef a, StringRef b)
constexpr bool operator<(StringRef a, StringRef b)
constexpr bool operator<=(StringRef a, StringRef b)
constexpr bool operator>(StringRef a, StringRef b)
std::string operator+(StringRef a, StringRef b)