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

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

Issue 2136023002: arc: Abort booting ARC if the device is critically low on disk space. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: . Created 4 years, 5 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 (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 CHROMEOS_DBUS_CRYPTOHOME_CLIENT_H_ 5 #ifndef CHROMEOS_DBUS_CRYPTOHOME_CLIENT_H_
6 #define CHROMEOS_DBUS_CRYPTOHOME_CLIENT_H_ 6 #define CHROMEOS_DBUS_CRYPTOHOME_CLIENT_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <string> 10 #include <string>
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
51 bool return_status, 51 bool return_status,
52 int return_code)> 52 int return_code)>
53 AsyncCallStatusHandler; 53 AsyncCallStatusHandler;
54 // A callback to handle AsyncCallStatusWithData signals. 54 // A callback to handle AsyncCallStatusWithData signals.
55 typedef base::Callback<void(int async_id, 55 typedef base::Callback<void(int async_id,
56 bool return_status, 56 bool return_status,
57 const std::string& data)> 57 const std::string& data)>
58 AsyncCallStatusWithDataHandler; 58 AsyncCallStatusWithDataHandler;
59 // A callback to handle responses of AsyncXXX methods. 59 // A callback to handle responses of AsyncXXX methods.
60 typedef base::Callback<void(int async_id)> AsyncMethodCallback; 60 typedef base::Callback<void(int async_id)> AsyncMethodCallback;
61 // A callback for GetFreeDiskSpace().
62 typedef base::Callback<void(DBusMethodCallStatus call_status,
63 uint64_t disk_free_bytes)>
64 GetFreeDiskSpaceCallback;
61 // A callback for GetSystemSalt(). 65 // A callback for GetSystemSalt().
62 typedef base::Callback<void(DBusMethodCallStatus call_status, 66 typedef base::Callback<void(DBusMethodCallStatus call_status,
63 const std::vector<uint8_t>& system_salt)> 67 const std::vector<uint8_t>& system_salt)>
64 GetSystemSaltCallback; 68 GetSystemSaltCallback;
65 // A callback to handle LowDiskSpace signals. 69 // A callback to handle LowDiskSpace signals.
66 typedef base::Callback<void(uint64_t disk_free_bytes)> LowDiskSpaceHandler; 70 typedef base::Callback<void(uint64_t disk_free_bytes)> LowDiskSpaceHandler;
67 // A callback for WaitForServiceToBeAvailable(). 71 // A callback for WaitForServiceToBeAvailable().
68 typedef base::Callback<void(bool service_is_ready)> 72 typedef base::Callback<void(bool service_is_ready)>
69 WaitForServiceToBeAvailableCallback; 73 WaitForServiceToBeAvailableCallback;
70 // A callback to handle responses of Pkcs11GetTpmTokenInfo method. The result 74 // A callback to handle responses of Pkcs11GetTpmTokenInfo method. The result
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after
146 const AsyncMethodCallback& callback) = 0; 150 const AsyncMethodCallback& callback) = 0;
147 151
148 // Calls RenameCryptohome method. |callback| is called after the method 152 // Calls RenameCryptohome method. |callback| is called after the method
149 // call succeeds. 153 // call succeeds.
150 virtual void RenameCryptohome( 154 virtual void RenameCryptohome(
151 const cryptohome::Identification& cryptohome_id_from, 155 const cryptohome::Identification& cryptohome_id_from,
152 const cryptohome::Identification& cryptohome_id_to, 156 const cryptohome::Identification& cryptohome_id_to,
153 const ProtobufMethodCallback& callback) = 0; 157 const ProtobufMethodCallback& callback) = 0;
154 158
155 // Calls GetAccountDiskUsage method. |callback| is called after the method 159 // Calls GetAccountDiskUsage method. |callback| is called after the method
156 // call succeeds 160 // call succeeds.
157 virtual void GetAccountDiskUsage(const cryptohome::Identification& account_id, 161 virtual void GetAccountDiskUsage(const cryptohome::Identification& account_id,
158 const ProtobufMethodCallback& callback) = 0; 162 const ProtobufMethodCallback& callback) = 0;
159 163
164 // Calls GetFreeDiskSpace method. |callback| is called after the method
165 // call succeeds.
166 virtual void GetFreeDiskSpace(const GetFreeDiskSpaceCallback& callback) = 0;
Junichi Uekawa 2016/07/15 00:29:40 Why do we need a DBus message to cryptohome to cal
167
160 // Calls GetSystemSalt method. |callback| is called after the method call 168 // Calls GetSystemSalt method. |callback| is called after the method call
161 // succeeds. 169 // succeeds.
162 virtual void GetSystemSalt(const GetSystemSaltCallback& callback) = 0; 170 virtual void GetSystemSalt(const GetSystemSaltCallback& callback) = 0;
163 171
164 // Calls GetSanitizedUsername method. |callback| is called after the method 172 // Calls GetSanitizedUsername method. |callback| is called after the method
165 // call succeeds. 173 // call succeeds.
166 virtual void GetSanitizedUsername( 174 virtual void GetSanitizedUsername(
167 const cryptohome::Identification& cryptohome_id, 175 const cryptohome::Identification& cryptohome_id,
168 const StringDBusMethodCallback& callback) = 0; 176 const StringDBusMethodCallback& callback) = 0;
169 177
(...skipping 389 matching lines...) Expand 10 before | Expand all | Expand 10 after
559 // Create() should be used instead. 567 // Create() should be used instead.
560 CryptohomeClient(); 568 CryptohomeClient();
561 569
562 private: 570 private:
563 DISALLOW_COPY_AND_ASSIGN(CryptohomeClient); 571 DISALLOW_COPY_AND_ASSIGN(CryptohomeClient);
564 }; 572 };
565 573
566 } // namespace chromeos 574 } // namespace chromeos
567 575
568 #endif // CHROMEOS_DBUS_CRYPTOHOME_CLIENT_H_ 576 #endif // CHROMEOS_DBUS_CRYPTOHOME_CLIENT_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698