Update broken references to image assets
[chromium-blink-merge.git] / chrome / browser / chromeos / file_system_provider / registry_interface.h
blob3ef80f78d5bacdcf5bd42bfa6813c0620d167641
1 // Copyright 2014 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.
5 #ifndef CHROME_BROWSER_CHROMEOS_FILE_SYSTEM_PROVIDER_REGISTRY_INTERFACE_H_
6 #define CHROME_BROWSER_CHROMEOS_FILE_SYSTEM_PROVIDER_REGISTRY_INTERFACE_H_
8 #include <string>
9 #include <vector>
11 #include "base/files/file_path.h"
12 #include "base/memory/scoped_ptr.h"
13 #include "chrome/browser/chromeos/file_system_provider/provided_file_system_info.h"
14 #include "chrome/browser/chromeos/file_system_provider/watcher.h"
16 namespace chromeos {
17 namespace file_system_provider {
19 // Remembers and restores file systems in a persistent storage.
20 class RegistryInterface {
21 public:
22 struct RestoredFileSystem;
24 // List of file systems together with their watchers to be remounted.
25 typedef std::vector<RestoredFileSystem> RestoredFileSystems;
27 // Information about a file system to be restored.
28 struct RestoredFileSystem {
29 RestoredFileSystem();
30 ~RestoredFileSystem();
32 std::string extension_id;
33 MountOptions options;
34 Watchers watchers;
37 virtual ~RegistryInterface();
39 // Remembers the file system in preferences, in order to remount after a
40 // reboot.
41 virtual void RememberFileSystem(
42 const ProvidedFileSystemInfo& file_system_info,
43 const Watchers& watchers) = 0;
45 // Removes the file system from preferences, so it is not remounmted anymore
46 // after a reboot.
47 virtual void ForgetFileSystem(const std::string& extension_id,
48 const std::string& file_system_id) = 0;
50 // Restores from preferences file systems mounted previously by the
51 // |extension_id| providing extension. The returned list should be used to
52 // remount them.
53 virtual scoped_ptr<RestoredFileSystems> RestoreFileSystems(
54 const std::string& extension_id) = 0;
56 // Updates a tag for the specified watcher.
57 virtual void UpdateWatcherTag(const ProvidedFileSystemInfo& file_system_info,
58 const Watcher& watcher) = 0;
61 } // namespace file_system_provider
62 } // namespace chromeos
64 #endif // CHROME_BROWSER_CHROMEOS_FILE_SYSTEM_PROVIDER_REGISTRY_INTERFACE_H_