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

Side by Side Diff: webkit/fileapi/syncable/sync_status_code.h

Issue 15806012: Move webkit/fileapi/syncable/* code to webkit/browser/fileapi (final!) (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 6 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 | Annotate | Revision Log
« no previous file with comments | « webkit/fileapi/syncable/sync_file_type.h ('k') | webkit/fileapi/syncable/sync_status_code.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright (c) 2012 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
5 #ifndef WEBKIT_FILEAPI_SYNCABLE_SYNC_STATUS_CODE_H_
6 #define WEBKIT_FILEAPI_SYNCABLE_SYNC_STATUS_CODE_H_
7
8 #include <string>
9
10 #include "base/platform_file.h"
11 #include "webkit/storage/webkit_storage_export.h"
12
13 namespace leveldb {
14 class Status;
15 }
16
17 namespace sync_file_system {
18
19 enum SyncStatusCode {
20 SYNC_STATUS_OK = 0,
21 SYNC_STATUS_UNKNOWN = -1000,
22
23 // Generic error code which is not specifically related to a specific
24 // submodule error code (yet).
25 SYNC_STATUS_FAILED = -1001,
26
27 // Basic ones that could be directly mapped to PlatformFileError.
28 SYNC_FILE_ERROR_FAILED = -1,
29 SYNC_FILE_ERROR_IN_USE = -2,
30 SYNC_FILE_ERROR_EXISTS = -3,
31 SYNC_FILE_ERROR_NOT_FOUND = -4,
32 SYNC_FILE_ERROR_ACCESS_DENIED = -5,
33 SYNC_FILE_ERROR_TOO_MANY_OPENED = -6,
34 SYNC_FILE_ERROR_NO_MEMORY = -7,
35 SYNC_FILE_ERROR_NO_SPACE = -8,
36 SYNC_FILE_ERROR_NOT_A_DIRECTORY = -9,
37 SYNC_FILE_ERROR_INVALID_OPERATION = -10,
38 SYNC_FILE_ERROR_SECURITY = -11,
39 SYNC_FILE_ERROR_ABORT = -12,
40 SYNC_FILE_ERROR_NOT_A_FILE = -13,
41 SYNC_FILE_ERROR_NOT_EMPTY = -14,
42 SYNC_FILE_ERROR_INVALID_URL = -15,
43
44 // Database related errors.
45 SYNC_DATABASE_ERROR_NOT_FOUND = -16,
46 SYNC_DATABASE_ERROR_CORRUPTION = -17,
47 SYNC_DATABASE_ERROR_IO_ERROR = -18,
48 SYNC_DATABASE_ERROR_FAILED = -19,
49
50 // Sync specific status code.
51 SYNC_STATUS_FILE_BUSY = -100,
52 SYNC_STATUS_HAS_CONFLICT = -101,
53 SYNC_STATUS_NO_CONFLICT = -102,
54 SYNC_STATUS_ABORT = -103,
55 SYNC_STATUS_NO_CHANGE_TO_SYNC = -104,
56 SYNC_STATUS_RETRY = -105,
57 SYNC_STATUS_NETWORK_ERROR = -106,
58 SYNC_STATUS_AUTHENTICATION_FAILED = -107,
59 SYNC_STATUS_UNKNOWN_ORIGIN = -108,
60 SYNC_STATUS_NOT_MODIFIED = -109,
61 SYNC_STATUS_SYNC_DISABLED = -110,
62 };
63
64 WEBKIT_STORAGE_EXPORT std::string SyncStatusCodeToString(SyncStatusCode status);
65
66 WEBKIT_STORAGE_EXPORT SyncStatusCode LevelDBStatusToSyncStatusCode(
67 const leveldb::Status& status);
68
69 WEBKIT_STORAGE_EXPORT SyncStatusCode PlatformFileErrorToSyncStatusCode(
70 base::PlatformFileError file_error);
71
72 } // namespace sync_file_system
73
74 #endif // WEBKIT_FILEAPI_SYNCABLE_SYNC_STATUS_CODE_H_
OLDNEW
« no previous file with comments | « webkit/fileapi/syncable/sync_file_type.h ('k') | webkit/fileapi/syncable/sync_status_code.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698