MCPcopy Create free account
hub / github.com/DFHack/dfhack / hasEnding

Method hasEnding

library/Types.cpp:46–56  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

44}
45
46bool DFHack::hasEnding (std::string const &fullString, std::string const &ending)
47{
48 if (fullString.length() > ending.length())
49 {
50 return (0 == fullString.compare (fullString.length() - ending.length(), ending.length(), ending));
51 }
52 else
53 {
54 return false;
55 }
56}
57
58df::general_ref *DFHack::findRef(std::vector<df::general_ref*> &vec, df::general_ref_type type)
59{

Callers

nothing calls this directly

Calls 1

lengthMethod · 0.80

Tested by

no test coverage detected