Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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 NET_DISK_CACHE_SIMPLE_SIMPLE_BACKEND_IMPL_H_ | 5 #ifndef NET_DISK_CACHE_SIMPLE_SIMPLE_BACKEND_IMPL_H_ |
| 6 #define NET_DISK_CACHE_SIMPLE_SIMPLE_BACKEND_IMPL_H_ | 6 #define NET_DISK_CACHE_SIMPLE_SIMPLE_BACKEND_IMPL_H_ |
| 7 | 7 |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include <memory> | 10 #include <memory> |
| (...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 113 int CalculateSizeOfEntriesBetween( | 113 int CalculateSizeOfEntriesBetween( |
| 114 base::Time initial_time, | 114 base::Time initial_time, |
| 115 base::Time end_time, | 115 base::Time end_time, |
| 116 const CompletionCallback& callback) override; | 116 const CompletionCallback& callback) override; |
| 117 std::unique_ptr<Iterator> CreateIterator() override; | 117 std::unique_ptr<Iterator> CreateIterator() override; |
| 118 void GetStats(base::StringPairs* stats) override; | 118 void GetStats(base::StringPairs* stats) override; |
| 119 void OnExternalCacheHit(const std::string& key) override; | 119 void OnExternalCacheHit(const std::string& key) override; |
| 120 size_t DumpMemoryStats( | 120 size_t DumpMemoryStats( |
| 121 base::trace_event::ProcessMemoryDump* pmd, | 121 base::trace_event::ProcessMemoryDump* pmd, |
| 122 const std::string& parent_absolute_name) const override; | 122 const std::string& parent_absolute_name) const override; |
| 123 uint8_t GetMemoryEntryData(const std::string& key) override; | |
|
pasko
2017/06/29 16:31:49
nit: maybe GetEntryInMemoryData, which would be cl
gavinp
2017/08/04 18:42:54
+1
Maks Orlovich
2017/08/23 19:29:05
Acknowledged.
Maks Orlovich
2017/08/23 19:29:05
Copy-pasted this comment to the interface CL, sinc
| |
| 124 void SetMemoryEntryData(const std::string& key, uint8_t data) override; | |
| 123 | 125 |
| 124 private: | 126 private: |
| 125 class SimpleIterator; | 127 class SimpleIterator; |
| 126 friend class SimpleIterator; | 128 friend class SimpleIterator; |
| 127 | 129 |
| 128 using EntryMap = std::unordered_map<uint64_t, SimpleEntryImpl*>; | 130 using EntryMap = std::unordered_map<uint64_t, SimpleEntryImpl*>; |
| 129 | 131 |
| 130 using InitializeIndexCallback = | 132 using InitializeIndexCallback = |
| 131 base::Callback<void(base::Time mtime, uint64_t max_size, int result)>; | 133 base::Callback<void(base::Time mtime, uint64_t max_size, int result)>; |
| 132 | 134 |
| (...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 230 // operations to be run at the completion of the Doom. | 232 // operations to be run at the completion of the Doom. |
| 231 std::unordered_map<uint64_t, std::vector<base::Closure>> | 233 std::unordered_map<uint64_t, std::vector<base::Closure>> |
| 232 entries_pending_doom_; | 234 entries_pending_doom_; |
| 233 | 235 |
| 234 net::NetLog* const net_log_; | 236 net::NetLog* const net_log_; |
| 235 }; | 237 }; |
| 236 | 238 |
| 237 } // namespace disk_cache | 239 } // namespace disk_cache |
| 238 | 240 |
| 239 #endif // NET_DISK_CACHE_SIMPLE_SIMPLE_BACKEND_IMPL_H_ | 241 #endif // NET_DISK_CACHE_SIMPLE_SIMPLE_BACKEND_IMPL_H_ |
| OLD | NEW |