MCPcopy Create free account
hub / github.com/apache/trafficserver / IsNoCasePrefixOf

Function IsNoCasePrefixOf

include/tscore/ink_string.h:384–388  ·  view source on GitHub ↗

Check for prefix. @return @c true if @a lhs is a prefix (ignoring case) of @a rhs.

Source from the content-addressed store, hash-verified

382/// Check for prefix.
383/// @return @c true if @a lhs is a prefix (ignoring case) of @a rhs.
384inline bool
385IsNoCasePrefixOf(std::string_view const &lhs, std::string_view const &rhs)
386{
387 return lhs.size() <= rhs.size() && 0 == strncasecmp(lhs.data(), rhs.data(), lhs.size());
388}
389
390/// Check for prefix.
391/// @return @c true if @a lhs is a prefix of @a rhs.

Callers 1

protocol_containsMethod · 0.85

Calls 2

sizeMethod · 0.45
dataMethod · 0.45

Tested by

no test coverage detected