Fix emulator build error
[platform/framework/web/chromium-efl.git] / components / browsing_topics / annotator_noop.cc
1 // Copyright 2023 The Chromium Authors
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #include "components/browsing_topics/annotator_noop.h"
6
7 namespace browsing_topics {
8
9 AnnotatorNoOp::AnnotatorNoOp() = default;
10 AnnotatorNoOp::~AnnotatorNoOp() = default;
11
12 void AnnotatorNoOp::BatchAnnotate(BatchAnnotationCallback callback,
13                                   const std::vector<std::string>& inputs) {
14   std::vector<Annotation> annotations;
15   annotations.reserve(inputs.size());
16   for (const std::string& input : inputs) {
17     annotations.push_back(Annotation(input));
18   }
19   std::move(callback).Run(annotations);
20 }
21
22 void AnnotatorNoOp::NotifyWhenModelAvailable(base::OnceClosure callback) {}
23
24 absl::optional<optimization_guide::ModelInfo>
25 AnnotatorNoOp::GetBrowsingTopicsModelInfo() const {
26   return absl::nullopt;
27 }
28
29 }  // namespace browsing_topics