Chromium Code Reviews| Index: chromeos/dbus/upstart_client.h |
| diff --git a/chromeos/dbus/upstart_client.h b/chromeos/dbus/upstart_client.h |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..e0ee6b41612c5a93c4bd159802da7a02c6c9cc78 |
| --- /dev/null |
| +++ b/chromeos/dbus/upstart_client.h |
| @@ -0,0 +1,37 @@ |
| +// Copyright (c) 2016 The Chromium Authors. All rights reserved. |
|
hashimoto
2016/11/14 22:09:41
nit: No (c) after Copyright.
(see https://chromium
Roman Sorokin (ftl)
2016/11/15 10:04:10
Done.
|
| +// Use of this source code is governed by a BSD-style license that can be |
| +// found in the LICENSE file. |
| + |
| +#ifndef CHROMEOS_DBUS_UPSTART_CLIENT_H_ |
| +#define CHROMEOS_DBUS_UPSTART_CLIENT_H_ |
| + |
| +#include "chromeos/chromeos_export.h" |
| +#include "chromeos/dbus/dbus_client.h" |
| + |
| +namespace chromeos { |
| + |
| +// UpstartClient is used to communicate with the com.ubuntu.Upstart |
| +// sevice. All methods should be called from the origin thread (UI thread) which |
| +// initializes the DBusThreadManager instance. |
| +class CHROMEOS_EXPORT UpstartClient : public DBusClient { |
| + public: |
| + ~UpstartClient() override; |
| + |
| + // Factory function, creates a new instance and returns ownership. |
| + // For normal usage, access the singleton via DBusThreadManager::Get(). |
| + static UpstartClient* Create(); |
| + |
| + // Non-blocking signal to Upstart to start authpolicyd. |
|
hashimoto
2016/11/14 22:09:41
Using the term "signal" here is confusing as it's
Roman Sorokin (ftl)
2016/11/15 10:04:10
Done.
|
| + virtual void StartAuthPolicyService() = 0; |
| + |
| + protected: |
| + // Create() should be used instead. |
| + UpstartClient(); |
| + |
| + private: |
| + DISALLOW_COPY_AND_ASSIGN(UpstartClient); |
| +}; |
| + |
| +} // namespace chromeos |
| + |
| +#endif // CHROMEOS_DBUS_UPSTART_CLIENT_H_ |