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

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

Issue 2323133002: Speed up ARC boot if the user launches ARC app while ARC is not ready (Closed)
Patch Set: Fix unit_tests Created 4 years, 3 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 | « chromeos/dbus/mock_session_manager_client.h ('k') | chromeos/dbus/session_manager_client.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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_SESSION_MANAGER_CLIENT_H_ 5 #ifndef CHROMEOS_DBUS_SESSION_MANAGER_CLIENT_H_
6 #define CHROMEOS_DBUS_SESSION_MANAGER_CLIENT_H_ 6 #define CHROMEOS_DBUS_SESSION_MANAGER_CLIENT_H_
7 7
8 #include <map> 8 #include <map>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 214 matching lines...) Expand 10 before | Expand all | Expand 10 after
225 // failed to start an instance or session manager can not be reached). 225 // failed to start an instance or session manager can not be reached).
226 virtual void StartArcInstance(const cryptohome::Identification& cryptohome_id, 226 virtual void StartArcInstance(const cryptohome::Identification& cryptohome_id,
227 const ArcCallback& callback) = 0; 227 const ArcCallback& callback) = 0;
228 228
229 // Asynchronously stops the ARC instance. Upon completion, invokes 229 // Asynchronously stops the ARC instance. Upon completion, invokes
230 // |callback| with the result; true on success, false on failure (either 230 // |callback| with the result; true on success, false on failure (either
231 // session manager failed to stop an instance or session manager can not be 231 // session manager failed to stop an instance or session manager can not be
232 // reached). 232 // reached).
233 virtual void StopArcInstance(const ArcCallback& callback) = 0; 233 virtual void StopArcInstance(const ArcCallback& callback) = 0;
234 234
235 // Prioritizes the ARC instance by removing cgroups restrictions that
236 // session_manager applies to the instance by default. Upon completion,
237 // invokes |callback| with the result; true on success, false on failure.
238 // Calling this multiple times is okay. Such calls except the first one
239 // will be ignored.
240 virtual void PrioritizeArcInstance(const ArcCallback& callback) = 0;
241
235 // Asynchronously retrieves the timestamp which ARC instance is invoked or 242 // Asynchronously retrieves the timestamp which ARC instance is invoked or
236 // returns false if there is no ARC instance or ARC is not available. 243 // returns false if there is no ARC instance or ARC is not available.
237 virtual void GetArcStartTime(const GetArcStartTimeCallback& callback) = 0; 244 virtual void GetArcStartTime(const GetArcStartTimeCallback& callback) = 0;
238 245
239 // Asynchronously removes all ARC user data for the user whose cryptohome is 246 // Asynchronously removes all ARC user data for the user whose cryptohome is
240 // located by |cryptohome_id|. Upon completion, invokes |callback| with the 247 // located by |cryptohome_id|. Upon completion, invokes |callback| with the
241 // result; true on success, false on failure (either session manager failed 248 // result; true on success, false on failure (either session manager failed
242 // to remove user data or session manager can not be reached). 249 // to remove user data or session manager can not be reached).
243 virtual void RemoveArcData(const cryptohome::Identification& cryptohome_id, 250 virtual void RemoveArcData(const cryptohome::Identification& cryptohome_id,
244 const ArcCallback& callback) = 0; 251 const ArcCallback& callback) = 0;
245 252
246 // Creates the instance. 253 // Creates the instance.
247 static SessionManagerClient* Create(DBusClientImplementationType type); 254 static SessionManagerClient* Create(DBusClientImplementationType type);
248 255
249 ~SessionManagerClient() override; 256 ~SessionManagerClient() override;
250 257
251 protected: 258 protected:
252 // Create() should be used instead. 259 // Create() should be used instead.
253 SessionManagerClient(); 260 SessionManagerClient();
254 261
255 private: 262 private:
256 DISALLOW_COPY_AND_ASSIGN(SessionManagerClient); 263 DISALLOW_COPY_AND_ASSIGN(SessionManagerClient);
257 }; 264 };
258 265
259 } // namespace chromeos 266 } // namespace chromeos
260 267
261 #endif // CHROMEOS_DBUS_SESSION_MANAGER_CLIENT_H_ 268 #endif // CHROMEOS_DBUS_SESSION_MANAGER_CLIENT_H_
OLDNEW
« no previous file with comments | « chromeos/dbus/mock_session_manager_client.h ('k') | chromeos/dbus/session_manager_client.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698