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

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

Issue 248213004: Record connection, registration, and receiving activities. (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
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_H_ 5 #ifndef GOOGLE_APIS_GCM_GCM_CLIENT_H_
6 #define GOOGLE_APIS_GCM_GCM_CLIENT_H_ 6 #define GOOGLE_APIS_GCM_GCM_CLIENT_H_
7 7
8 #include <map> 8 #include <map>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after
98 bool is_recording; 98 bool is_recording;
99 bool gcm_client_created; 99 bool gcm_client_created;
100 std::string gcm_client_state; 100 std::string gcm_client_state;
101 bool connection_client_created; 101 bool connection_client_created;
102 std::string connection_state; 102 std::string connection_state;
103 uint64 android_id; 103 uint64 android_id;
104 std::vector<std::string> registered_app_ids; 104 std::vector<std::string> registered_app_ids;
105 int send_queue_size; 105 int send_queue_size;
106 int resend_queue_size; 106 int resend_queue_size;
107 107
108 std::vector<GCMStatsRecorder::ConnectionActivity> connection_activities;
Nicolas Zea 2014/04/23 23:37:04 I wonder if all of these should be encapsulated in
juyik 2014/04/24 00:53:45 Done.
109 std::vector<GCMStatsRecorder::RegistrationActivity> registration_activities;
110 std::vector<GCMStatsRecorder::ReceivingActivity> receiving_activities;
108 std::vector<GCMStatsRecorder::SendingActivity> sending_activities; 111 std::vector<GCMStatsRecorder::SendingActivity> sending_activities;
109 }; 112 };
110 113
111 // A delegate interface that allows the GCMClient instance to interact with 114 // A delegate interface that allows the GCMClient instance to interact with
112 // its caller, i.e. notifying asynchronous event. 115 // its caller, i.e. notifying asynchronous event.
113 class Delegate { 116 class Delegate {
114 public: 117 public:
115 // Called when the registration completed successfully or an error occurs. 118 // Called when the registration completed successfully or an error occurs.
116 // |app_id|: application ID. 119 // |app_id|: application ID.
117 // |registration_id|: non-empty if the registration completed successfully. 120 // |registration_id|: non-empty if the registration completed successfully.
(...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after
221 // Clear all recorded GCM activity logs. 224 // Clear all recorded GCM activity logs.
222 virtual void ClearActivityLogs() = 0; 225 virtual void ClearActivityLogs() = 0;
223 226
224 // Gets internal states and statistics. 227 // Gets internal states and statistics.
225 virtual GCMStatistics GetStatistics() const = 0; 228 virtual GCMStatistics GetStatistics() const = 0;
226 }; 229 };
227 230
228 } // namespace gcm 231 } // namespace gcm
229 232
230 #endif // GOOGLE_APIS_GCM_GCM_CLIENT_H_ 233 #endif // GOOGLE_APIS_GCM_GCM_CLIENT_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698