| 548 | } |
| 549 | |
| 550 | void SearchMarks::SetSales(std::vector<FeatureID> const & features, bool hasSale) |
| 551 | { |
| 552 | if (features.empty()) |
| 553 | return; |
| 554 | |
| 555 | ProcessMarks([&features, hasSale](SearchMarkPoint * mark) -> base::ControlFlow |
| 556 | { |
| 557 | ASSERT(std::is_sorted(features.cbegin(), features.cend()), ()); |
| 558 | if (std::binary_search(features.cbegin(), features.cend(), mark->GetFeatureID())) |
| 559 | mark->SetSale(hasSale); |
| 560 | return base::ControlFlow::Continue; |
| 561 | }); |
| 562 | } |
| 563 | |
| 564 | bool SearchMarks::IsThereSearchMarkForFeature(FeatureID const & featureId) const |
| 565 | { |