MCPcopy Create free account
hub / github.com/VitalAudio/visage / endsWith

Method endsWith

visage_utils/string_utils.h:296–299  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

294 }
295
296 bool endsWith(const std::u32string& suffix) const {
297 return string_.size() >= suffix.size() &&
298 0 == string_.compare(string_.size() - suffix.size(), suffix.size(), suffix);
299 }
300
301 bool endsWith(const std::string& suffix) const { return endsWith(convertToUtf32(suffix)); }
302 bool endsWith(char suffix) const { return !string_.empty() && string_.back() == suffix; }

Callers 1

Calls 2

sizeMethod · 0.45
compareMethod · 0.45

Tested by

no test coverage detected