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

Side by Side Diff: base/prefs/persistent_pref_store.h

Issue 169323003: Implementation of leveldb-backed PrefStore (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: write every 10s Created 6 years, 9 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 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 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 BASE_PREFS_PERSISTENT_PREF_STORE_H_ 5 #ifndef BASE_PREFS_PERSISTENT_PREF_STORE_H_
6 #define BASE_PREFS_PERSISTENT_PREF_STORE_H_ 6 #define BASE_PREFS_PERSISTENT_PREF_STORE_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/prefs/base_prefs_export.h" 10 #include "base/prefs/base_prefs_export.h"
(...skipping 12 matching lines...) Expand all
23 PREF_READ_ERROR_NONE = 0, 23 PREF_READ_ERROR_NONE = 0,
24 PREF_READ_ERROR_JSON_PARSE, 24 PREF_READ_ERROR_JSON_PARSE,
25 PREF_READ_ERROR_JSON_TYPE, 25 PREF_READ_ERROR_JSON_TYPE,
26 PREF_READ_ERROR_ACCESS_DENIED, 26 PREF_READ_ERROR_ACCESS_DENIED,
27 PREF_READ_ERROR_FILE_OTHER, 27 PREF_READ_ERROR_FILE_OTHER,
28 PREF_READ_ERROR_FILE_LOCKED, 28 PREF_READ_ERROR_FILE_LOCKED,
29 PREF_READ_ERROR_NO_FILE, 29 PREF_READ_ERROR_NO_FILE,
30 PREF_READ_ERROR_JSON_REPEAT, 30 PREF_READ_ERROR_JSON_REPEAT,
31 PREF_READ_ERROR_OTHER, 31 PREF_READ_ERROR_OTHER,
32 PREF_READ_ERROR_FILE_NOT_SPECIFIED, 32 PREF_READ_ERROR_FILE_NOT_SPECIFIED,
33 PREF_READ_ERROR_LEVELDB_IO_ERROR,
34 PREF_READ_ERROR_LEVELDB_DESTROYED_REOPEN_SUCCESS,
35 PREF_READ_ERROR_LEVELDB_REPAIRED_REOPEN_SUCCESS,
36 PREF_READ_ERROR_LEVELDB_DESTROY_FAILED,
37 PREF_READ_ERROR_LEVELDB_DESTROYED_REOPEN_FAILED,
38 PREF_READ_ERROR_LEVELDB_REPAIRED_REOPEN_FAILED,
33 PREF_READ_ERROR_MAX_ENUM 39 PREF_READ_ERROR_MAX_ENUM
34 }; 40 };
35 41
36 class ReadErrorDelegate { 42 class ReadErrorDelegate {
37 public: 43 public:
38 virtual ~ReadErrorDelegate() {} 44 virtual ~ReadErrorDelegate() {}
39 45
40 virtual void OnError(PrefReadError error) = 0; 46 virtual void OnError(PrefReadError error) = 0;
41 }; 47 };
42 48
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
75 virtual void ReadPrefsAsync(ReadErrorDelegate* error_delegate) = 0; 81 virtual void ReadPrefsAsync(ReadErrorDelegate* error_delegate) = 0;
76 82
77 // Lands any pending writes to disk. 83 // Lands any pending writes to disk.
78 virtual void CommitPendingWrite() = 0; 84 virtual void CommitPendingWrite() = 0;
79 85
80 protected: 86 protected:
81 virtual ~PersistentPrefStore() {} 87 virtual ~PersistentPrefStore() {}
82 }; 88 };
83 89
84 #endif // BASE_PREFS_PERSISTENT_PREF_STORE_H_ 90 #endif // BASE_PREFS_PERSISTENT_PREF_STORE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698