Lines Matching refs:Child
31 for (const auto &Child : Children) in AndIterator() local
32 ReachedEnd |= Child->reachedEnd(); in AndIterator()
68 for (const auto &Child : Children) in consume() local
69 Boost *= Child->consume(); in consume()
81 for (const auto &Child : Children) { in dump() local
82 OS << Separator << *Child; in dump()
100 for (auto &Child : Children) { in sync() local
101 Child->advanceTo(SyncID); in sync()
102 ReachedEnd |= Child->reachedEnd(); in sync()
109 if (Child->peek() > SyncID) { in sync()
110 SyncID = Child->peek(); in sync()
143 for (const auto &Child : Children) in reachedEnd() local
144 if (!Child->reachedEnd()) in reachedEnd()
153 for (const auto &Child : Children) in advance() local
154 if (!Child->reachedEnd() && Child->peek() == SmallestID) in advance()
155 Child->advance(); in advance()
161 for (const auto &Child : Children) in advanceTo() local
162 if (!Child->reachedEnd()) in advanceTo()
163 Child->advanceTo(ID); in advanceTo()
172 for (const auto &Child : Children) in peek() local
173 if (!Child->reachedEnd()) in peek()
174 Result = std::min(Result, Child->peek()); in peek()
185 for (const auto &Child : Children) in consume() local
186 if (!Child->reachedEnd() && Child->peek() == ID) in consume()
187 Boost = std::max(Boost, Child->consume()); in consume()
193 for (const auto &Child : Children) in estimateSize() local
194 Size = std::max(Size, Child->estimateSize()); in estimateSize()
202 for (const auto &Child : Children) { in dump() local
203 OS << Separator << *Child; in dump()
283 BoostIterator(std::unique_ptr<Iterator> Child, float Factor) in BoostIterator() argument
284 : Child(std::move(Child)), Factor(Factor) {} in BoostIterator()
286 bool reachedEnd() const override { return Child->reachedEnd(); } in reachedEnd()
288 void advance() override { Child->advance(); } in advance()
290 void advanceTo(DocID ID) override { Child->advanceTo(ID); } in advanceTo()
292 DocID peek() const override { return Child->peek(); } in peek()
294 float consume() override { return Child->consume() * Factor; } in consume()
296 size_t estimateSize() const override { return Child->estimateSize(); } in estimateSize()
300 return OS << "(* " << Factor << ' ' << *Child << ')'; in dump()
303 std::unique_ptr<Iterator> Child; member in clang::clangd::dex::__anon27ed63d30111::BoostIterator
313 LimitIterator(std::unique_ptr<Iterator> Child, size_t Limit) in LimitIterator() argument
314 : Child(std::move(Child)), Limit(Limit), ItemsLeft(Limit) {} in LimitIterator()
317 return ItemsLeft == 0 || Child->reachedEnd(); in reachedEnd()
320 void advance() override { Child->advance(); } in advance()
322 void advanceTo(DocID ID) override { Child->advanceTo(ID); } in advanceTo()
324 DocID peek() const override { return Child->peek(); } in peek()
331 return Child->consume(); in consume()
335 return std::min(Child->estimateSize(), Limit); in estimateSize()
340 return OS << "(LIMIT " << Limit << " " << *Child << ')'; in dump()
343 std::unique_ptr<Iterator> Child; member in clang::clangd::dex::__anon27ed63d30111::LimitIterator
360 for (auto &Child : Children) { in intersect() local
361 switch (Child->kind()) { in intersect()
365 return std::move(Child); // Intersection is empty. in intersect()
368 auto &NewChildren = static_cast<AndIterator *>(Child.get())->Children; in intersect()
374 RealChildren.push_back(std::move(Child)); in intersect()
390 for (auto &Child : Children) { in unionOf() local
391 switch (Child->kind()) { in unionOf()
396 auto &NewChildren = static_cast<OrIterator *>(Child.get())->Children; in unionOf()
404 RealChildren.push_back(std::move(Child)); in unionOf()
425 std::unique_ptr<Iterator> Corpus::boost(std::unique_ptr<Iterator> Child, in boost() argument
428 return Child; in boost()
429 if (Child->kind() == Iterator::Kind::False) in boost()
430 return Child; in boost()
431 return std::make_unique<BoostIterator>(std::move(Child), Factor); in boost()
434 std::unique_ptr<Iterator> Corpus::limit(std::unique_ptr<Iterator> Child, in limit() argument
436 if (Child->kind() == Iterator::Kind::False) in limit()
437 return Child; in limit()
438 return std::make_unique<LimitIterator>(std::move(Child), Limit); in limit()