Chromium Code Reviews| Index: components/gcm_driver/gcm_message_status.h |
| diff --git a/components/gcm_driver/gcm_message_status.h b/components/gcm_driver/gcm_message_status.h |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..e9e25b56d5f9bcdc23a9a031bf5cda3c07e0f410 |
| --- /dev/null |
| +++ b/components/gcm_driver/gcm_message_status.h |
| @@ -0,0 +1,30 @@ |
| +// Copyright 2014 The Chromium Authors. All rights reserved. |
|
Peter Beverloo
2017/02/13 13:47:07
2017
harkness
2017/02/14 19:22:29
oops
|
| +// Use of this source code is governed by a BSD-style license that can be |
| +// found in the LICENSE file. |
| + |
| +#ifndef COMPONENTS_GCM_DRIVER_GCM_MESSAGE_STATUS_H_ |
| +#define COMPONENTS_GCM_DRIVER_GCM_MESSAGE_STATUS_H_ |
| + |
| +namespace gcm { |
| + |
| +// Enumeration to be used for describing the status of a GCM message. |
| +enum class GCMMessageStatus { |
| + // 0 reserved for unresolved. |
| + GCM_UNRESOLVED = 0, |
| + // 1 reserved for success. |
| + GCM_SUCCESS = 1, |
| + |
| + // 2 - 99 reserved for the GCM communication error types. |
| + GCM_INVALID_SUBTYPE = 2, |
| + GCM_INVALID_SENDER_ID = 3, |
| + GCM_NO_REGISTRATION = 4, |
| + GCM_ENCRYPTION_FAILURE = 5, |
|
Peter Beverloo
2017/02/13 13:47:07
nit: *DE*CRYPTION_FAILURE
harkness
2017/02/14 19:22:29
Done.
|
| + GCM_UNKNOWN_MESSAGE_TYPE = 6, |
| + GCM_NO_APP_HANDLER = 7, |
|
Peter Beverloo
2017/02/13 13:47:07
GCM_INVALID_APP so that it can be generalized to A
harkness
2017/02/14 19:22:29
Done.
|
| +}; |
| + |
| +using MessageReceiptCallback = base::Callback<void(GCMMessageStatus)>; |
|
Peter Beverloo
2017/02/13 13:47:07
include //base/callback.h
harkness
2017/02/14 19:22:29
Done.
|
| + |
| +} // namespace gcm |
| + |
| +#endif // COMPONENTS_GCM_DRIVER_GCM_MESSAGE_STATUS_H_ |