OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 CHROME_BROWSER_STORAGE_MONITOR_STORAGE_MONITOR_H_ | 5 #ifndef CHROME_BROWSER_STORAGE_MONITOR_STORAGE_MONITOR_H_ |
6 #define CHROME_BROWSER_STORAGE_MONITOR_STORAGE_MONITOR_H_ | 6 #define CHROME_BROWSER_STORAGE_MONITOR_STORAGE_MONITOR_H_ |
7 | 7 |
8 #include <map> | 8 #include <map> |
9 #include <string> | 9 #include <string> |
10 #include <vector> | 10 #include <vector> |
11 | 11 |
12 #include "base/callback.h" | 12 #include "base/callback.h" |
13 #include "base/files/file_path.h" | 13 #include "base/files/file_path.h" |
14 #include "base/observer_list_threadsafe.h" | 14 #include "base/observer_list_threadsafe.h" |
15 #include "base/strings/string16.h" | 15 #include "base/strings/string16.h" |
16 #include "base/synchronization/lock.h" | 16 #include "base/synchronization/lock.h" |
17 #include "chrome/browser/storage_monitor/storage_info.h" | 17 #include "chrome/browser/storage_monitor/storage_info.h" |
18 | 18 |
19 class ChromeBrowserMainPartsLinux; | 19 class ChromeBrowserMainPartsLinux; |
20 class ChromeBrowserMainPartsMac; | 20 class ChromeBrowserMainPartsMac; |
21 class MediaGalleriesPlatformAppBrowserTest; | 21 class MediaGalleriesPlatformAppBrowserTest; |
22 class MediaGalleriesPrivateApiTest; | 22 class MediaGalleriesPrivateApiTest; |
23 class MediaGalleriesPrivateEjectApiTest; | 23 class MediaGalleriesPrivateEjectApiTest; |
24 class SystemInfoStorageApiTest; | 24 class SystemStorageApiTest; |
25 class SystemInfoStorageEjectApiTest; | 25 class SystemStorageEjectApiTest; |
26 | 26 |
27 namespace device { | 27 namespace device { |
28 class MediaTransferProtocolManager; | 28 class MediaTransferProtocolManager; |
29 } | 29 } |
30 | 30 |
31 namespace chrome { | 31 namespace chrome { |
32 | 32 |
33 class MediaFileSystemRegistryTest; | 33 class MediaFileSystemRegistryTest; |
34 class RemovableStorageObserver; | 34 class RemovableStorageObserver; |
35 class TransientDeviceIds; | 35 class TransientDeviceIds; |
(...skipping 95 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
131 | 131 |
132 virtual void EjectDevice( | 132 virtual void EjectDevice( |
133 const std::string& device_id, | 133 const std::string& device_id, |
134 base::Callback<void(EjectStatus)> callback); | 134 base::Callback<void(EjectStatus)> callback); |
135 | 135 |
136 protected: | 136 protected: |
137 friend class ::MediaGalleriesPlatformAppBrowserTest; | 137 friend class ::MediaGalleriesPlatformAppBrowserTest; |
138 friend class ::MediaGalleriesPrivateApiTest; | 138 friend class ::MediaGalleriesPrivateApiTest; |
139 friend class ::MediaGalleriesPrivateEjectApiTest; | 139 friend class ::MediaGalleriesPrivateEjectApiTest; |
140 friend class MediaFileSystemRegistryTest; | 140 friend class MediaFileSystemRegistryTest; |
141 friend class ::SystemInfoStorageApiTest; | 141 friend class ::SystemStorageApiTest; |
142 friend class ::SystemInfoStorageEjectApiTest; | 142 friend class ::SystemStorageEjectApiTest; |
143 | 143 |
144 StorageMonitor(); | 144 StorageMonitor(); |
145 | 145 |
146 virtual Receiver* receiver() const; | 146 virtual Receiver* receiver() const; |
147 | 147 |
148 // Called to initialize the storage monitor. | 148 // Called to initialize the storage monitor. |
149 virtual void Init() = 0; | 149 virtual void Init() = 0; |
150 | 150 |
151 // Called by subclasses to mark the storage monitor as | 151 // Called by subclasses to mark the storage monitor as |
152 // fully initialized. Must be called on the UI thread. | 152 // fully initialized. Must be called on the UI thread. |
(...skipping 26 matching lines...) Expand all Loading... |
179 | 179 |
180 // Map of all known storage devices,including fixed and removable storages. | 180 // Map of all known storage devices,including fixed and removable storages. |
181 StorageMap storage_map_; | 181 StorageMap storage_map_; |
182 | 182 |
183 scoped_ptr<TransientDeviceIds> transient_device_ids_; | 183 scoped_ptr<TransientDeviceIds> transient_device_ids_; |
184 }; | 184 }; |
185 | 185 |
186 } // namespace chrome | 186 } // namespace chrome |
187 | 187 |
188 #endif // CHROME_BROWSER_STORAGE_MONITOR_STORAGE_MONITOR_H_ | 188 #endif // CHROME_BROWSER_STORAGE_MONITOR_STORAGE_MONITOR_H_ |
OLD | NEW |