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

Side by Side Diff: chromeos/dbus/image_loader_client.h

Issue 2744453003: Mount image upon component installed (Closed)
Patch Set: incremental change Created 3 years, 9 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
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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_DBUS_IMAGE_LOADER_CLIENT_H_ 5 #ifndef CHROMEOS_DBUS_IMAGE_LOADER_CLIENT_H_
6 #define CHROMEOS_DBUS_IMAGE_LOADER_CLIENT_H_ 6 #define CHROMEOS_DBUS_IMAGE_LOADER_CLIENT_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/callback.h" 10 #include "base/callback.h"
(...skipping 10 matching lines...) Expand all
21 public: 21 public:
22 ~ImageLoaderClient() override; 22 ~ImageLoaderClient() override;
23 23
24 // Registers a component by copying from |component_folder_abs_path| into its 24 // Registers a component by copying from |component_folder_abs_path| into its
25 // internal storage, if and only if, the component passes verification. 25 // internal storage, if and only if, the component passes verification.
26 virtual void RegisterComponent(const std::string& name, 26 virtual void RegisterComponent(const std::string& name,
27 const std::string& version, 27 const std::string& version,
28 const std::string& component_folder_abs_path, 28 const std::string& component_folder_abs_path,
29 const BoolDBusMethodCallback& callback) = 0; 29 const BoolDBusMethodCallback& callback) = 0;
30 30
31 // same as above except the |callback| needs one more parameter.
32 virtual void RegisterComponent(const std::string& name,
33 const std::string& version,
34 const std::string& component_folder_abs_path,
35 const BoolDBusMethodCallbackPm& callback) = 0;
36
31 // Mount a component given the |name| and return the mount point (if call is 37 // Mount a component given the |name| and return the mount point (if call is
32 // successful). 38 // successful).
33 virtual void LoadComponent(const std::string& name, 39 virtual void LoadComponent(const std::string& name,
34 const StringDBusMethodCallback& callback) = 0; 40 const StringDBusMethodCallback& callback) = 0;
35 41
36 // Factory function, creates a new instance and returns ownership. 42 // Factory function, creates a new instance and returns ownership.
37 // For normal usage, access the singleton via DBusThreadManager::Get(). 43 // For normal usage, access the singleton via DBusThreadManager::Get().
38 static ImageLoaderClient* Create(); 44 static ImageLoaderClient* Create();
39 45
40 protected: 46 protected:
41 // Create() should be used instead. 47 // Create() should be used instead.
42 ImageLoaderClient(); 48 ImageLoaderClient();
43 49
44 private: 50 private:
45 DISALLOW_COPY_AND_ASSIGN(ImageLoaderClient); 51 DISALLOW_COPY_AND_ASSIGN(ImageLoaderClient);
46 }; 52 };
47 53
48 } // namespace chromeos 54 } // namespace chromeos
49 55
50 #endif // CHROMEOS_DBUS_IMAGE_LOADER_CLIENT_H_ 56 #endif // CHROMEOS_DBUS_IMAGE_LOADER_CLIENT_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698