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

Side by Side Diff: net/disk_cache/memory/mem_entry_impl.h

Issue 2591743002: Implement a method to get the total size of a cache entry (Closed)
Patch Set: rebase Created 3 years, 11 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
« no previous file with comments | « net/disk_cache/entry_unittest.cc ('k') | net/disk_cache/memory/mem_entry_impl.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 NET_DISK_CACHE_MEMORY_MEM_ENTRY_IMPL_H_ 5 #ifndef NET_DISK_CACHE_MEMORY_MEM_ENTRY_IMPL_H_
6 #define NET_DISK_CACHE_MEMORY_MEM_ENTRY_IMPL_H_ 6 #define NET_DISK_CACHE_MEMORY_MEM_ENTRY_IMPL_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <memory> 10 #include <memory>
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after
97 // the entry was modified, also update |last_modified_|. 97 // the entry was modified, also update |last_modified_|.
98 void UpdateStateOnUse(EntryModified modified_enum); 98 void UpdateStateOnUse(EntryModified modified_enum);
99 99
100 // From disk_cache::Entry: 100 // From disk_cache::Entry:
101 void Doom() override; 101 void Doom() override;
102 void Close() override; 102 void Close() override;
103 std::string GetKey() const override; 103 std::string GetKey() const override;
104 base::Time GetLastUsed() const override; 104 base::Time GetLastUsed() const override;
105 base::Time GetLastModified() const override; 105 base::Time GetLastModified() const override;
106 int32_t GetDataSize(int index) const override; 106 int32_t GetDataSize(int index) const override;
107 int64_t GetEntrySize() const override;
107 int ReadData(int index, 108 int ReadData(int index,
108 int offset, 109 int offset,
109 IOBuffer* buf, 110 IOBuffer* buf,
110 int buf_len, 111 int buf_len,
111 const CompletionCallback& callback) override; 112 const CompletionCallback& callback) override;
112 int WriteData(int index, 113 int WriteData(int index,
113 int offset, 114 int offset,
114 IOBuffer* buf, 115 IOBuffer* buf,
115 int buf_len, 116 int buf_len,
116 const CompletionCallback& callback, 117 const CompletionCallback& callback,
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after
185 bool doomed_; // True if this entry was removed from the cache. 186 bool doomed_; // True if this entry was removed from the cache.
186 187
187 net::NetLogWithSource net_log_; 188 net::NetLogWithSource net_log_;
188 189
189 DISALLOW_COPY_AND_ASSIGN(MemEntryImpl); 190 DISALLOW_COPY_AND_ASSIGN(MemEntryImpl);
190 }; 191 };
191 192
192 } // namespace disk_cache 193 } // namespace disk_cache
193 194
194 #endif // NET_DISK_CACHE_MEMORY_MEM_ENTRY_IMPL_H_ 195 #endif // NET_DISK_CACHE_MEMORY_MEM_ENTRY_IMPL_H_
OLDNEW
« no previous file with comments | « net/disk_cache/entry_unittest.cc ('k') | net/disk_cache/memory/mem_entry_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698