| OLD | NEW |
| 1 // Copyright (c) 2013 The LevelDB Authors. All rights reserved. | 1 // Copyright (c) 2013 The LevelDB 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. See the AUTHORS file for names of contributors. | 3 // found in the LICENSE file. See the AUTHORS file for names of contributors. |
| 4 | 4 |
| 5 #ifndef THIRD_PARTY_LEVELDATABASE_ENV_CHROMIUM_H_ | 5 #ifndef THIRD_PARTY_LEVELDATABASE_ENV_CHROMIUM_H_ |
| 6 #define THIRD_PARTY_LEVELDATABASE_ENV_CHROMIUM_H_ | 6 #define THIRD_PARTY_LEVELDATABASE_ENV_CHROMIUM_H_ |
| 7 | 7 |
| 8 #include <deque> | 8 #include <deque> |
| 9 #include <set> | 9 #include <set> |
| 10 #include <string> | 10 #include <string> |
| (...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 54 const std::string& message, | 54 const std::string& message, |
| 55 MethodID method); | 55 MethodID method); |
| 56 | 56 |
| 57 enum ErrorParsingResult { | 57 enum ErrorParsingResult { |
| 58 METHOD_ONLY, | 58 METHOD_ONLY, |
| 59 METHOD_AND_PFE, | 59 METHOD_AND_PFE, |
| 60 METHOD_AND_ERRNO, | 60 METHOD_AND_ERRNO, |
| 61 NONE, | 61 NONE, |
| 62 }; | 62 }; |
| 63 | 63 |
| 64 ErrorParsingResult ParseMethodAndError(const char* string, | 64 ErrorParsingResult ParseMethodAndError(const leveldb::Status& status, |
| 65 MethodID* method, | 65 MethodID* method, |
| 66 int* error); | 66 int* error); |
| 67 int GetCorruptionCode(const leveldb::Status& status); | 67 int GetCorruptionCode(const leveldb::Status& status); |
| 68 int GetNumCorruptionCodes(); | 68 int GetNumCorruptionCodes(); |
| 69 std::string GetCorruptionMessage(const leveldb::Status& status); | 69 std::string GetCorruptionMessage(const leveldb::Status& status); |
| 70 bool IndicatesDiskFull(const leveldb::Status& status); | 70 bool IndicatesDiskFull(const leveldb::Status& status); |
| 71 bool IsIOError(const leveldb::Status& status); | 71 bool IsIOError(const leveldb::Status& status); |
| 72 | 72 |
| 73 class UMALogger { | 73 class UMALogger { |
| 74 public: | 74 public: |
| (...skipping 128 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 203 void (*function)(void*); | 203 void (*function)(void*); |
| 204 }; | 204 }; |
| 205 typedef std::deque<BGItem> BGQueue; | 205 typedef std::deque<BGItem> BGQueue; |
| 206 BGQueue queue_; | 206 BGQueue queue_; |
| 207 LockTable locks_; | 207 LockTable locks_; |
| 208 }; | 208 }; |
| 209 | 209 |
| 210 } // namespace leveldb_env | 210 } // namespace leveldb_env |
| 211 | 211 |
| 212 #endif // THIRD_PARTY_LEVELDATABASE_ENV_CHROMIUM_H_ | 212 #endif // THIRD_PARTY_LEVELDATABASE_ENV_CHROMIUM_H_ |
| OLD | NEW |