MCPcopy Create free account
hub / github.com/catboost/catboost / Contains

Method Contains

util/folder/path.cpp:311–326  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

309}
310
311bool TFsPath::Contains(const TString& component) const {
312 if (!IsDefined()) {
313 return false;
314 }
315
316 TFsPath path = *this;
317 while (path.Parent() != path) {
318 if (path.GetName() == component) {
319 return true;
320 }
321
322 path = path.Parent();
323 }
324
325 return false;
326}
327
328void TFsPath::List(TVector<TFsPath>& files) const {
329 TVector<TString> names;

Callers 6

Y_UNIT_TESTFunction · 0.45
ParseMethod · 0.45
TestEnsureExistsMethod · 0.45
Y_UNIT_TESTFunction · 0.45
VerifyPathFunction · 0.45

Calls 2

ParentMethod · 0.80
GetNameMethod · 0.45

Tested by 2

TestEnsureExistsMethod · 0.36