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

Side by Side Diff: chrome/browser/chromeos/arc/arc_auth_service_impl.h

Issue 1553613002: Add ArcAuthService to handle IPC request from ARC (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: dummy auth code Created 4 years, 11 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
(Empty)
1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef CHROME_BROWSER_CHROMEOS_ARC_ARC_AUTH_SERVICE_IMPL_H_
6 #define CHROME_BROWSER_CHROMEOS_ARC_ARC_AUTH_SERVICE_IMPL_H_
7
8 #include "base/macros.h"
9 #include "components/arc/arc_bridge_service.h"
10 #include "components/arc/auth/arc_auth_service.h"
11 #include "components/arc/common/auth.mojom.h"
12 #include "mojo/public/cpp/bindings/binding.h"
13
14 namespace arc {
15
16 // This class proxies the request from the client to fetch an auth code from
17 // LSO.
18 class ArcAuthServiceImpl : public ArcAuthService,
19 public AuthHost,
20 public ArcBridgeService::Observer {
21 public:
22 ArcAuthServiceImpl();
23 virtual ~ArcAuthServiceImpl();
achuithb 2016/01/04 23:41:59 use override
victorhsieh 2016/01/05 00:39:14 Should I override a destructor?
achuithb 2016/01/05 01:24:53 Yes
24
25 // Overrides ArcBridgeService::Observer
achuithb 2016/01/04 23:41:59 Make everything below private. period at the end o
victorhsieh 2016/01/05 00:39:14 Done.
26 void OnAuthInstanceReady() override;
27
28 // Overrides AuthHost
achuithb 2016/01/04 23:41:59 period
victorhsieh 2016/01/05 00:39:14 Done.
29 void GetAuthCode(const GetAuthCodeCallback& callback) override;
30
31 // Overrides ArcAuthService
32 // Starts listening to state changes of the ArcBridgeService.
33 // This must be called before the bridge service starts bootstrapping.
34 void StartObservingBridgeServiceChanges();
35
36 private:
37 mojo::Binding<AuthHost> binding_;
38
39 DISALLOW_COPY_AND_ASSIGN(ArcAuthServiceImpl);
40 };
41
42 } // namespace arc
43
44 #endif // CHROME_BROWSER_CHROMEOS_ARC_ARC_AUTH_SERVICE_IMPL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698