Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(283)

Side by Side Diff: chromeos/components/tether/host_scan_cache.h

Issue 2857723002: [CrOS Tether] Fix build breakage. (Closed)
Patch Set: Created 3 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2017 The Chromium Authors. All rights reserved. 1 // Copyright 2017 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CHROMEOS_COMPONENTS_TETHER_HOST_SCAN_CACHE_H_ 5 #ifndef CHROMEOS_COMPONENTS_TETHER_HOST_SCAN_CACHE_H_
6 #define CHROMEOS_COMPONENTS_TETHER_HOST_SCAN_CACHE_H_ 6 #define CHROMEOS_COMPONENTS_TETHER_HOST_SCAN_CACHE_H_
7 7
8 #include <memory> 8 #include <memory>
9 #include <unordered_map> 9 #include <unordered_map>
10 10
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
71 // Removes all scan results from the cache unless they correspond to the 71 // Removes all scan results from the cache unless they correspond to the
72 // active host; the active host must always remain in the cache while 72 // active host; the active host must always remain in the cache while
73 // connecting/connected to ensure the UI is up to date. 73 // connecting/connected to ensure the UI is up to date.
74 virtual void ClearCacheExceptForActiveHost(); 74 virtual void ClearCacheExceptForActiveHost();
75 75
76 // TetherHostResponseRecorder::Observer: 76 // TetherHostResponseRecorder::Observer:
77 void OnPreviouslyConnectedHostIdsChanged() override; 77 void OnPreviouslyConnectedHostIdsChanged() override;
78 78
79 class TimerFactory { 79 class TimerFactory {
80 public: 80 public:
81 virtual std::unique_ptr<base::Timer> CreateOneShotTimer(); 81 virtual std::unique_ptr<base::Timer> CreateOneShotTimer() = 0;
82 }; 82 };
83 83
84 private: 84 private:
85 friend class HostScanCacheTest; 85 friend class HostScanCacheTest;
86 86
87 void SetTimerFactoryForTest( 87 void SetTimerFactoryForTest(
88 std::unique_ptr<TimerFactory> timer_factory_for_test); 88 std::unique_ptr<TimerFactory> timer_factory_for_test);
89 89
90 bool HasConnectedToHost(const std::string& tether_network_guid); 90 bool HasConnectedToHost(const std::string& tether_network_guid);
91 void StartTimer(const std::string& tether_network_guid); 91 void StartTimer(const std::string& tether_network_guid);
(...skipping 14 matching lines...) Expand all
106 base::WeakPtrFactory<HostScanCache> weak_ptr_factory_; 106 base::WeakPtrFactory<HostScanCache> weak_ptr_factory_;
107 107
108 DISALLOW_COPY_AND_ASSIGN(HostScanCache); 108 DISALLOW_COPY_AND_ASSIGN(HostScanCache);
109 }; 109 };
110 110
111 } // namespace tether 111 } // namespace tether
112 112
113 } // namespace chromeos 113 } // namespace chromeos
114 114
115 #endif // CHROMEOS_COMPONENTS_TETHER_HOST_SCAN_CACHE_H_ 115 #endif // CHROMEOS_COMPONENTS_TETHER_HOST_SCAN_CACHE_H_
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698