1 // Copyright 2020 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4 
5 #ifndef CHROMEOS_COMPONENTS_BLOOM_PUBLIC_CPP_BLOOM_CONTROLLER_H_
6 #define CHROMEOS_COMPONENTS_BLOOM_PUBLIC_CPP_BLOOM_CONTROLLER_H_
7 
8 #include <memory>
9 
10 #include "base/component_export.h"
11 #include "chromeos/components/bloom/public/cpp/bloom_interaction_resolution.h"
12 
13 namespace chromeos {
14 namespace bloom {
15 
16 // Main controller for the Bloom integration.
COMPONENT_EXPORT(BLOOM)17 class COMPONENT_EXPORT(BLOOM) BloomController {
18  public:
19   BloomController();
20   BloomController(const BloomController&) = delete;
21   BloomController& operator=(const BloomController&) = delete;
22   virtual ~BloomController();
23 
24   // Access the existing Bloom controller.
25   static BloomController* Get();
26 
27   // Starts an interaction. This will ask the user for a screenshot, analyze the
28   // content and display the result.
29   virtual void StartInteraction() = 0;
30   virtual bool HasInteraction() const = 0;
31   virtual void StopInteraction(BloomInteractionResolution resolution) = 0;
32 };
33 
34 }  // namespace bloom
35 }  // namespace chromeos
36 
37 #endif  // CHROMEOS_COMPONENTS_BLOOM_PUBLIC_CPP_BLOOM_CONTROLLER_H_
38