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

Side by Side Diff: components/gcm_driver/gcm_activity.h

Issue 666133002: Standardize usage of virtual/override/final in components/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 2 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 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_ACTIVITY_H_ 5 #ifndef COMPONENTS_GCM_DRIVER_GCM_ACTIVITY_H_
6 #define COMPONENTS_GCM_DRIVER_GCM_ACTIVITY_H_ 6 #define COMPONENTS_GCM_DRIVER_GCM_ACTIVITY_H_
7 7
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
11 #include "base/time/time.h" 11 #include "base/time/time.h"
12 12
13 namespace gcm { 13 namespace gcm {
14 14
15 // Contains data that are common to all activity kinds below. 15 // Contains data that are common to all activity kinds below.
16 struct Activity { 16 struct Activity {
17 Activity(); 17 Activity();
18 virtual ~Activity(); 18 virtual ~Activity();
19 19
20 base::Time time; 20 base::Time time;
21 std::string event; // A short description of the event. 21 std::string event; // A short description of the event.
22 std::string details; // Any additional detail about the event. 22 std::string details; // Any additional detail about the event.
23 }; 23 };
24 24
25 // Contains relevant data of a connection activity. 25 // Contains relevant data of a connection activity.
26 struct ConnectionActivity : Activity { 26 struct ConnectionActivity : Activity {
27 ConnectionActivity(); 27 ConnectionActivity();
28 virtual ~ConnectionActivity(); 28 ~ConnectionActivity() override;
29 }; 29 };
30 30
31 // Contains relevant data of a check-in activity. 31 // Contains relevant data of a check-in activity.
32 struct CheckinActivity : Activity { 32 struct CheckinActivity : Activity {
33 CheckinActivity(); 33 CheckinActivity();
34 virtual ~CheckinActivity(); 34 ~CheckinActivity() override;
35 }; 35 };
36 36
37 // Contains relevant data of a registration/unregistration step. 37 // Contains relevant data of a registration/unregistration step.
38 struct RegistrationActivity : Activity { 38 struct RegistrationActivity : Activity {
39 RegistrationActivity(); 39 RegistrationActivity();
40 virtual ~RegistrationActivity(); 40 ~RegistrationActivity() override;
41 41
42 std::string app_id; 42 std::string app_id;
43 std::string sender_ids; // Comma separated sender ids. 43 std::string sender_ids; // Comma separated sender ids.
44 }; 44 };
45 45
46 // Contains relevant data of a message receiving event. 46 // Contains relevant data of a message receiving event.
47 struct ReceivingActivity : Activity { 47 struct ReceivingActivity : Activity {
48 ReceivingActivity(); 48 ReceivingActivity();
49 virtual ~ReceivingActivity(); 49 ~ReceivingActivity() override;
50 50
51 std::string app_id; 51 std::string app_id;
52 std::string from; 52 std::string from;
53 int message_byte_size; 53 int message_byte_size;
54 }; 54 };
55 55
56 // Contains relevant data of a send-message step. 56 // Contains relevant data of a send-message step.
57 struct SendingActivity : Activity { 57 struct SendingActivity : Activity {
58 SendingActivity(); 58 SendingActivity();
59 virtual ~SendingActivity(); 59 ~SendingActivity() override;
60 60
61 std::string app_id; 61 std::string app_id;
62 std::string receiver_id; 62 std::string receiver_id;
63 std::string message_id; 63 std::string message_id;
64 }; 64 };
65 65
66 struct RecordedActivities { 66 struct RecordedActivities {
67 RecordedActivities(); 67 RecordedActivities();
68 virtual ~RecordedActivities(); 68 virtual ~RecordedActivities();
69 69
70 std::vector<CheckinActivity> checkin_activities; 70 std::vector<CheckinActivity> checkin_activities;
71 std::vector<ConnectionActivity> connection_activities; 71 std::vector<ConnectionActivity> connection_activities;
72 std::vector<RegistrationActivity> registration_activities; 72 std::vector<RegistrationActivity> registration_activities;
73 std::vector<ReceivingActivity> receiving_activities; 73 std::vector<ReceivingActivity> receiving_activities;
74 std::vector<SendingActivity> sending_activities; 74 std::vector<SendingActivity> sending_activities;
75 }; 75 };
76 76
77 } // namespace gcm 77 } // namespace gcm
78 78
79 #endif // COMPONENTS_GCM_DRIVER_GCM_ACTIVITY_H_ 79 #endif // COMPONENTS_GCM_DRIVER_GCM_ACTIVITY_H_
OLDNEW
« no previous file with comments | « components/gcm_driver/gcm_account_mapper_unittest.cc ('k') | components/gcm_driver/gcm_channel_status_request.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698