Lines Matching defs:prefix
218 * Return true if 's' starts with the prefix string 'prefix'.
221 startswith(const char *s, const char *prefix)
223 return (strncmp(s, prefix, strlen(prefix)) == 0);
228 * Return true if 's' starts with the prefix string 'prefix'.
231 startswith(const std::string &s, const char *prefix)
233 return (s.compare(0, strlen(prefix), prefix) == 0);
238 * Return true if 's' starts with the prefix string 'prefix'.
241 startswith(const std::string &s, const std::string &prefix)
243 return (s.compare(0, prefix.size(), prefix) == 0);