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

Side by Side Diff: components/sync/core/data_type_error_handler.h

Issue 2130453004: [Sync] Move //sync to //components/sync. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase. Created 4 years, 4 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 SYNC_INTERNAL_API_PUBLIC_DATA_TYPE_ERROR_HANDLER_H__ 5 #ifndef COMPONENTS_SYNC_CORE_DATA_TYPE_ERROR_HANDLER_H__
6 #define SYNC_INTERNAL_API_PUBLIC_DATA_TYPE_ERROR_HANDLER_H__ 6 #define COMPONENTS_SYNC_CORE_DATA_TYPE_ERROR_HANDLER_H__
7 7
8 #include <string> 8 #include <string>
9
9 #include "base/location.h" 10 #include "base/location.h"
10 11
11 #include "sync/api/sync_error.h" 12 #include "components/sync/api/sync_error.h"
12 #include "sync/internal_api/public/base/model_type.h" 13 #include "components/sync/base/model_type.h"
13 #include "sync/internal_api/public/util/unrecoverable_error_handler.h" 14 #include "components/sync/base/unrecoverable_error_handler.h"
14 15
15 namespace syncer { 16 namespace syncer {
16 17
17 class DataTypeErrorHandler { 18 class DataTypeErrorHandler {
18 public: 19 public:
19 // Call this to disable a datatype while it is running. This is usually 20 // Call this to disable a datatype while it is running. This is usually
20 // called for a runtime failure that is specific to a datatype. 21 // called for a runtime failure that is specific to a datatype.
21 virtual void OnSingleDataTypeUnrecoverableError(const SyncError& error) = 0; 22 virtual void OnSingleDataTypeUnrecoverableError(const SyncError& error) = 0;
22 23
23 // This will create a SyncError object. This will also upload a breakpad call 24 // This will create a SyncError object. This will also upload a breakpad call
24 // stack to crash server. A sync error usually means that sync has to be 25 // stack to crash server. A sync error usually means that sync has to be
25 // disabled either for that type or completely. 26 // disabled either for that type or completely.
26 virtual SyncError CreateAndUploadError( 27 virtual SyncError CreateAndUploadError(
27 const tracked_objects::Location& location, 28 const tracked_objects::Location& location,
28 const std::string& message, 29 const std::string& message,
29 ModelType type) = 0; 30 ModelType type) = 0;
30 31
31 protected: 32 protected:
32 virtual ~DataTypeErrorHandler() {} 33 virtual ~DataTypeErrorHandler() {}
33 }; 34 };
34 35
35 } // namespace syncer 36 } // namespace syncer
36 37
37 #endif // SYNC_INTERNAL_API_PUBLIC_DATA_TYPE_ERROR_HANDLER_H__ 38 #endif // COMPONENTS_SYNC_CORE_DATA_TYPE_ERROR_HANDLER_H__
OLDNEW
« no previous file with comments | « components/sync/core/data_type_debug_info_listener.cc ('k') | components/sync/core/delete_journal.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698