OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 COMPONENTS_GCM_DRIVER_GCM_STATS_RECORDER_IMPL_H_ | 5 #ifndef COMPONENTS_GCM_DRIVER_GCM_STATS_RECORDER_IMPL_H_ |
6 #define COMPONENTS_GCM_DRIVER_GCM_STATS_RECORDER_IMPL_H_ | 6 #define COMPONENTS_GCM_DRIVER_GCM_STATS_RECORDER_IMPL_H_ |
7 | 7 |
8 #include <deque> | 8 #include <deque> |
9 #include <string> | 9 #include <string> |
10 #include <vector> | 10 #include <vector> |
(...skipping 29 matching lines...) Expand all Loading... |
40 // Set a delegate to receive callback from the recorder. | 40 // Set a delegate to receive callback from the recorder. |
41 void SetDelegate(Delegate* delegate); | 41 void SetDelegate(Delegate* delegate); |
42 | 42 |
43 // Clear all recorded activities. | 43 // Clear all recorded activities. |
44 void Clear(); | 44 void Clear(); |
45 | 45 |
46 // GCMStatsRecorder implementation: | 46 // GCMStatsRecorder implementation: |
47 void RecordCheckinInitiated(uint64 android_id) override; | 47 void RecordCheckinInitiated(uint64 android_id) override; |
48 void RecordCheckinDelayedDueToBackoff(int64 delay_msec) override; | 48 void RecordCheckinDelayedDueToBackoff(int64 delay_msec) override; |
49 void RecordCheckinSuccess() override; | 49 void RecordCheckinSuccess() override; |
50 void RecordCheckinFailure(std::string status, bool will_retry) override; | 50 void RecordCheckinFailure(const std::string& status, |
| 51 bool will_retry) override; |
51 void RecordConnectionInitiated(const std::string& host) override; | 52 void RecordConnectionInitiated(const std::string& host) override; |
52 void RecordConnectionDelayedDueToBackoff(int64 delay_msec) override; | 53 void RecordConnectionDelayedDueToBackoff(int64 delay_msec) override; |
53 void RecordConnectionSuccess() override; | 54 void RecordConnectionSuccess() override; |
54 void RecordConnectionFailure(int network_error) override; | 55 void RecordConnectionFailure(int network_error) override; |
55 void RecordConnectionResetSignaled( | 56 void RecordConnectionResetSignaled( |
56 ConnectionFactory::ConnectionResetReason reason) override; | 57 ConnectionFactory::ConnectionResetReason reason) override; |
57 void RecordRegistrationSent(const std::string& app_id, | 58 void RecordRegistrationSent(const std::string& app_id, |
58 const std::string& source) override; | 59 const std::string& source) override; |
59 void RecordRegistrationResponse(const std::string& app_id, | 60 void RecordRegistrationResponse(const std::string& app_id, |
60 const std::string& source, | 61 const std::string& source, |
(...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
155 base::TimeTicks last_received_data_message_burst_start_time_; | 156 base::TimeTicks last_received_data_message_burst_start_time_; |
156 base::TimeTicks last_received_data_message_time_within_burst_; | 157 base::TimeTicks last_received_data_message_time_within_burst_; |
157 int64 received_data_message_burst_size_; | 158 int64 received_data_message_burst_size_; |
158 | 159 |
159 DISALLOW_COPY_AND_ASSIGN(GCMStatsRecorderImpl); | 160 DISALLOW_COPY_AND_ASSIGN(GCMStatsRecorderImpl); |
160 }; | 161 }; |
161 | 162 |
162 } // namespace gcm | 163 } // namespace gcm |
163 | 164 |
164 #endif // COMPONENTS_GCM_DRIVER_GCM_STATS_RECORDER_IMPL_H_ | 165 #endif // COMPONENTS_GCM_DRIVER_GCM_STATS_RECORDER_IMPL_H_ |
OLD | NEW |