| 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 CONTENT_PUBLIC_COMMON_PUSH_MESSAGING_STATUS_H_ | 5 #ifndef CONTENT_PUBLIC_COMMON_PUSH_MESSAGING_STATUS_H_ |
| 6 #define CONTENT_PUBLIC_COMMON_PUSH_MESSAGING_STATUS_H_ | 6 #define CONTENT_PUBLIC_COMMON_PUSH_MESSAGING_STATUS_H_ |
| 7 | 7 |
| 8 namespace content { | 8 namespace content { |
| 9 | 9 |
| 10 // Push registration success/error codes for internal use & reporting in UMA. | 10 // Push registration success/error codes for internal use & reporting in UMA. |
| (...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 51 | 51 |
| 52 // Registration failed because the public key could not be retrieved. | 52 // Registration failed because the public key could not be retrieved. |
| 53 PUSH_REGISTRATION_STATUS_PUBLIC_KEY_UNAVAILABLE = 11, | 53 PUSH_REGISTRATION_STATUS_PUBLIC_KEY_UNAVAILABLE = 11, |
| 54 | 54 |
| 55 // NOTE: Do not renumber these as that would confuse interpretation of | 55 // NOTE: Do not renumber these as that would confuse interpretation of |
| 56 // previously logged data. When making changes, also update the enum list | 56 // previously logged data. When making changes, also update the enum list |
| 57 // in tools/metrics/histograms/histograms.xml to keep it in sync, and | 57 // in tools/metrics/histograms/histograms.xml to keep it in sync, and |
| 58 // update PUSH_REGISTRATION_STATUS_LAST below. | 58 // update PUSH_REGISTRATION_STATUS_LAST below. |
| 59 | 59 |
| 60 PUSH_REGISTRATION_STATUS_LAST = | 60 PUSH_REGISTRATION_STATUS_LAST = |
| 61 PUSH_REGISTRATION_STATUS_PUBLIC_KEY_UNAVAILABLE | 61 PUSH_REGISTRATION_STATUS_INCOGNITO_PERMISSION_DENIED |
| 62 }; | 62 }; |
| 63 | 63 |
| 64 // Push unregistration success/error codes for internal use & reporting in UMA. | 64 // Push unregistration success/error codes for internal use & reporting in UMA. |
| 65 enum PushUnregistrationStatus { | 65 enum PushUnregistrationStatus { |
| 66 // The unregistration was successful. | 66 // The unregistration was successful. |
| 67 PUSH_UNREGISTRATION_STATUS_SUCCESS_UNREGISTERED = 0, | 67 PUSH_UNREGISTRATION_STATUS_SUCCESS_UNREGISTERED = 0, |
| 68 | 68 |
| 69 // Unregistration was unnecessary, as the registration was not found. | 69 // Unregistration was unnecessary, as the registration was not found. |
| 70 PUSH_UNREGISTRATION_STATUS_SUCCESS_WAS_NOT_REGISTERED = 1, | 70 PUSH_UNREGISTRATION_STATUS_SUCCESS_WAS_NOT_REGISTERED = 1, |
| 71 | 71 |
| (...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 117 | 117 |
| 118 // Registration failed because the public key could not be retrieved. | 118 // Registration failed because the public key could not be retrieved. |
| 119 PUSH_GETREGISTRATION_STATUS_PUBLIC_KEY_UNAVAILABLE = 5, | 119 PUSH_GETREGISTRATION_STATUS_PUBLIC_KEY_UNAVAILABLE = 5, |
| 120 | 120 |
| 121 // NOTE: Do not renumber these as that would confuse interpretation of | 121 // NOTE: Do not renumber these as that would confuse interpretation of |
| 122 // previously logged data. When making changes, also update the enum list | 122 // previously logged data. When making changes, also update the enum list |
| 123 // in tools/metrics/histograms/histograms.xml to keep it in sync, and | 123 // in tools/metrics/histograms/histograms.xml to keep it in sync, and |
| 124 // update PUSH_GETREGISTRATION_STATUS_LAST below. | 124 // update PUSH_GETREGISTRATION_STATUS_LAST below. |
| 125 | 125 |
| 126 PUSH_GETREGISTRATION_STATUS_LAST = | 126 PUSH_GETREGISTRATION_STATUS_LAST = |
| 127 PUSH_GETREGISTRATION_STATUS_PUBLIC_KEY_UNAVAILABLE | 127 PUSH_GETREGISTRATION_STATUS_INCOGNITO_REGISTRATION_NOT_FOUND |
| 128 }; | 128 }; |
| 129 | 129 |
| 130 // Push message event success/error codes for internal use & reporting in UMA. | 130 // Push message event success/error codes for internal use & reporting in UMA. |
| 131 enum PushDeliveryStatus { | 131 enum PushDeliveryStatus { |
| 132 // The message was successfully delivered. | 132 // The message was successfully delivered. |
| 133 PUSH_DELIVERY_STATUS_SUCCESS = 0, | 133 PUSH_DELIVERY_STATUS_SUCCESS = 0, |
| 134 | 134 |
| 135 // The message could not be delivered because it was invalid. | 135 // The message could not be delivered because it was invalid. |
| 136 PUSH_DELIVERY_STATUS_INVALID_MESSAGE = 1, | 136 PUSH_DELIVERY_STATUS_INVALID_MESSAGE = 1, |
| 137 | 137 |
| (...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 187 PUSH_USER_VISIBLE_STATUS_REQUIRED_BUT_NOT_SHOWN_GRACE_EXCEEDED | 187 PUSH_USER_VISIBLE_STATUS_REQUIRED_BUT_NOT_SHOWN_GRACE_EXCEEDED |
| 188 }; | 188 }; |
| 189 | 189 |
| 190 const char* PushRegistrationStatusToString(PushRegistrationStatus status); | 190 const char* PushRegistrationStatusToString(PushRegistrationStatus status); |
| 191 | 191 |
| 192 const char* PushUnregistrationStatusToString(PushUnregistrationStatus status); | 192 const char* PushUnregistrationStatusToString(PushUnregistrationStatus status); |
| 193 | 193 |
| 194 } // namespace content | 194 } // namespace content |
| 195 | 195 |
| 196 #endif // CONTENT_PUBLIC_COMMON_PUSH_MESSAGING_STATUS_H_ | 196 #endif // CONTENT_PUBLIC_COMMON_PUSH_MESSAGING_STATUS_H_ |
| OLD | NEW |