OLD | NEW |
(Empty) | |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 #ifndef CHROME_BROWSER_SYNC_ENGINE_SYNC_ERROR_H_ |
| 5 #define CHROME_BROWSER_SYNC_ENGINE_SYNC_ERROR_H_ |
| 6 #pragma once |
| 7 |
| 8 #include <string> |
| 9 |
| 10 namespace sync_api { |
| 11 |
| 12 enum SyncErrorType { |
| 13 SUCCESS, |
| 14 NOT_MY_BIRTHDAY, |
| 15 THROTTLED, |
| 16 CLEAR_PENDING, |
| 17 TRANSIENT_ERROR, |
| 18 NON_RETRIABLE_ERROR, |
| 19 MIGRATION_DONE, |
| 20 INVALID_CREDENTIAL, |
| 21 UNKNOWN_ERROR |
| 22 }; |
| 23 |
| 24 enum ClientAction { |
| 25 UPGRADE_CLIENT, |
| 26 CLEAR_USER_DATA_AND_RESYNC, |
| 27 ENABLE_SYNC_ON_ACCOUNT, |
| 28 STOP_AND_RESTART_SYNC, |
| 29 DISABLE_SYNC_ON_CLIENT, |
| 30 UNKNOWN_ACTION |
| 31 }; |
| 32 |
| 33 struct SyncError { |
| 34 SyncErrorType error_type; |
| 35 std::string error_description; |
| 36 std::string url; |
| 37 ClientAction action; |
| 38 SyncError() : error_type(UNKNOWN_ERROR), action(UNKNOWN_ACTION) {} |
| 39 ~SyncError() {} |
| 40 }; |
| 41 } // namespace sync_api |
| 42 #endif // CHROME_BROWSER_SYNC_ENGINE_SYNC_ERROR_H_ |
OLD | NEW |