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

Side by Side Diff: google_apis/gcm/gcm_client_impl.h

Issue 226223005: Revert of Removing the mock-keychain related bool from GCMStore constructor (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 8 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 | « google_apis/gcm/engine/mcs_client_unittest.cc ('k') | google_apis/gcm/gcm_client_impl.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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 GOOGLE_APIS_GCM_GCM_CLIENT_IMPL_H_ 5 #ifndef GOOGLE_APIS_GCM_GCM_CLIENT_IMPL_H_
6 #define GOOGLE_APIS_GCM_GCM_CLIENT_IMPL_H_ 6 #define GOOGLE_APIS_GCM_GCM_CLIENT_IMPL_H_
7 7
8 #include <map> 8 #include <map>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
11 11
12 #include "base/compiler_specific.h" 12 #include "base/compiler_specific.h"
13 #include "base/memory/ref_counted.h" 13 #include "base/memory/ref_counted.h"
14 #include "base/memory/weak_ptr.h" 14 #include "base/memory/weak_ptr.h"
15 #include "base/stl_util.h" 15 #include "base/stl_util.h"
16 #include "google_apis/gcm/base/mcs_message.h" 16 #include "google_apis/gcm/base/mcs_message.h"
17 #include "google_apis/gcm/engine/gcm_store.h" 17 #include "google_apis/gcm/engine/gcm_store.h"
18 #include "google_apis/gcm/engine/mcs_client.h" 18 #include "google_apis/gcm/engine/mcs_client.h"
19 #include "google_apis/gcm/engine/registration_request.h" 19 #include "google_apis/gcm/engine/registration_request.h"
20 #include "google_apis/gcm/engine/unregistration_request.h" 20 #include "google_apis/gcm/engine/unregistration_request.h"
21 #include "google_apis/gcm/gcm_client.h" 21 #include "google_apis/gcm/gcm_client.h"
22 #include "google_apis/gcm/protocol/android_checkin.pb.h" 22 #include "google_apis/gcm/protocol/android_checkin.pb.h"
23 #include "net/base/net_log.h" 23 #include "net/base/net_log.h"
24 #include "net/url_request/url_request_context_getter.h" 24 #include "net/url_request/url_request_context_getter.h"
25 25
26 class GURL; 26 class GURL;
27 27
28 namespace base { 28 namespace base {
29 class Clock; 29 class Clock;
30 class FilePath;
31 } // namespace base 30 } // namespace base
32 31
33 namespace net { 32 namespace net {
34 class HttpNetworkSession; 33 class HttpNetworkSession;
35 } // namespace net 34 } // namespace net
36 35
37 namespace gcm { 36 namespace gcm {
38 37
39 class CheckinRequest; 38 class CheckinRequest;
40 class ConnectionFactory; 39 class ConnectionFactory;
41 class GCMClientImplTest; 40 class GCMClientImplTest;
42 41
43 // Helper class for building GCM internals. Allows tests to inject fake versions 42 // Helper class for building GCM internals. Allows tests to inject fake versions
44 // as necessary. 43 // as necessary.
45 class GCM_EXPORT GCMInternalsBuilder { 44 class GCM_EXPORT GCMInternalsBuilder {
46 public: 45 public:
47 GCMInternalsBuilder(); 46 GCMInternalsBuilder();
48 virtual ~GCMInternalsBuilder(); 47 virtual ~GCMInternalsBuilder();
49 48
50 virtual scoped_ptr<base::Clock> BuildClock(); 49 virtual scoped_ptr<base::Clock> BuildClock();
51 virtual scoped_ptr<GCMStore> BuildGCMStore(
52 const base::FilePath& path,
53 const scoped_refptr<base::SequencedTaskRunner>& blocking_task_runner);
54 virtual scoped_ptr<MCSClient> BuildMCSClient( 50 virtual scoped_ptr<MCSClient> BuildMCSClient(
55 const std::string& version, 51 const std::string& version,
56 base::Clock* clock, 52 base::Clock* clock,
57 ConnectionFactory* connection_factory, 53 ConnectionFactory* connection_factory,
58 GCMStore* gcm_store); 54 GCMStore* gcm_store);
59 virtual scoped_ptr<ConnectionFactory> BuildConnectionFactory( 55 virtual scoped_ptr<ConnectionFactory> BuildConnectionFactory(
60 const std::vector<GURL>& endpoints, 56 const std::vector<GURL>& endpoints,
61 const net::BackoffEntry::Policy& backoff_policy, 57 const net::BackoffEntry::Policy& backoff_policy,
62 scoped_refptr<net::HttpNetworkSession> network_session, 58 scoped_refptr<net::HttpNetworkSession> network_session,
63 net::NetLog* net_log); 59 net::NetLog* net_log);
(...skipping 199 matching lines...) Expand 10 before | Expand all | Expand 10 after
263 259
264 // Factory for creating references in callbacks. 260 // Factory for creating references in callbacks.
265 base::WeakPtrFactory<GCMClientImpl> weak_ptr_factory_; 261 base::WeakPtrFactory<GCMClientImpl> weak_ptr_factory_;
266 262
267 DISALLOW_COPY_AND_ASSIGN(GCMClientImpl); 263 DISALLOW_COPY_AND_ASSIGN(GCMClientImpl);
268 }; 264 };
269 265
270 } // namespace gcm 266 } // namespace gcm
271 267
272 #endif // GOOGLE_APIS_GCM_GCM_CLIENT_IMPL_H_ 268 #endif // GOOGLE_APIS_GCM_GCM_CLIENT_IMPL_H_
OLDNEW
« no previous file with comments | « google_apis/gcm/engine/mcs_client_unittest.cc ('k') | google_apis/gcm/gcm_client_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698