MCPcopy Create free account
hub / github.com/BYVoid/OpenCC / EndsWith

Function EndsWith

plugins/jieba/src/JiebaSegmentation.cpp:134–137  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

132}
133
134bool EndsWith(const std::string& text, const std::string& suffix) {
135 return text.size() >= suffix.size() &&
136 text.compare(text.size() - suffix.size(), suffix.size(), suffix) == 0;
137}
138
139bool LooksLikeOpenccMergedDict(const std::string& path) {
140 return EndsWith(path, ".ocd2");

Callers 1

Calls 2

sizeMethod · 0.45
compareMethod · 0.45

Tested by

no test coverage detected