MCPcopy Create free account
hub / github.com/ByConity/ByConity / isPrefix

Function isPrefix

src/DataTypes/ObjectUtils.cpp:270–279  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

268}
269
270static bool isPrefix(const PathInData::Parts & prefix, const PathInData::Parts & parts)
271{
272 if (prefix.size() > parts.size())
273 return false;
274
275 for (size_t i = 0; i < prefix.size(); ++i)
276 if (prefix[i].key != parts[i].key)
277 return false;
278 return true;
279}
280
281/// Returns true if there exists a prefix with matched names,
282/// but not matched structure (is Nested, number of dimensions).

Callers 1

Calls 1

sizeMethod · 0.45

Tested by

no test coverage detected