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

Unified Diff: chrome/browser/chromeos/arc/arc_policy_bridge.h

Issue 1754803003: Implement Stub for policy bridge to ARC (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Ordering and ordinal numbers in .mojom files, nits adressed Created 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/chromeos/arc/arc_auth_service.cc ('k') | chrome/browser/chromeos/arc/arc_policy_bridge.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/chromeos/arc/arc_policy_bridge.h
diff --git a/chrome/browser/chromeos/arc/arc_policy_bridge.h b/chrome/browser/chromeos/arc/arc_policy_bridge.h
new file mode 100644
index 0000000000000000000000000000000000000000..f6afaec698321a2c110ab07dbe18ad6d2baa8984
--- /dev/null
+++ b/chrome/browser/chromeos/arc/arc_policy_bridge.h
@@ -0,0 +1,44 @@
+// Copyright 2016 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef CHROME_BROWSER_CHROMEOS_ARC_ARC_POLICY_BRIDGE_H_
+#define CHROME_BROWSER_CHROMEOS_ARC_ARC_POLICY_BRIDGE_H_
+
+#include "components/arc/arc_bridge_service.h"
+#include "components/arc/arc_service.h"
+#include "components/policy/core/common/policy_service.h"
+#include "mojo/public/cpp/bindings/binding.h"
+
+namespace arc {
+
+class ArcPolicyBridge : public ArcService,
+ public ArcBridgeService::Observer,
+ public PolicyHost,
+ public policy::PolicyService::Observer {
+ public:
+ explicit ArcPolicyBridge(ArcBridgeService* bridge_service);
+ ~ArcPolicyBridge() override;
+
+ // ArcBridgeService::Observer overrides.
+ void OnPolicyInstanceReady() override;
+ void OnPolicyInstanceClosed() override;
+
+ // PolicyHost overrides.
+ void GetPolicies(const GetPoliciesCallback& callback) override;
+
+ // PolicyService::Observer overrides.
+ void OnPolicyUpdated(const policy::PolicyNamespace& ns,
+ const policy::PolicyMap& previous,
+ const policy::PolicyMap& current) override;
+
+ private:
+ mojo::Binding<PolicyHost> binding_;
+ policy::PolicyService* policy_service_ = nullptr;
+
+ DISALLOW_COPY_AND_ASSIGN(ArcPolicyBridge);
+};
+
+} // namespace arc
+
+#endif // CHROME_BROWSER_CHROMEOS_ARC_ARC_POLICY_BRIDGE_H_
« no previous file with comments | « chrome/browser/chromeos/arc/arc_auth_service.cc ('k') | chrome/browser/chromeos/arc/arc_policy_bridge.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698