OLD | NEW |
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 // See net/disk_cache/disk_cache.h for the public interface. | 5 // See net/disk_cache/disk_cache.h for the public interface. |
6 | 6 |
7 #ifndef NET_DISK_CACHE_RANKINGS_H_ | 7 #ifndef NET_DISK_CACHE_RANKINGS_H_ |
8 #define NET_DISK_CACHE_RANKINGS_H_ | 8 #define NET_DISK_CACHE_RANKINGS_H_ |
9 | 9 |
10 #include <list> | 10 #include <list> |
11 | 11 |
12 #include "base/memory/scoped_ptr.h" | 12 #include "base/memory/scoped_ptr.h" |
13 #include "net/disk_cache/addr.h" | 13 #include "net/disk_cache/addr.h" |
14 #include "net/disk_cache/mapped_file.h" | 14 #include "net/disk_cache/mapped_file.h" |
15 #include "net/disk_cache/storage_block.h" | 15 #include "net/disk_cache/storage_block.h" |
16 | 16 |
17 namespace disk_cache { | 17 namespace disk_cache { |
18 | 18 |
19 class BackendImpl; | 19 class BackendImpl; |
| 20 struct LruData; |
| 21 struct RankingsNode; |
| 22 typedef StorageBlock<RankingsNode> CacheRankingsBlock; |
20 | 23 |
21 // Type of crashes generated for the unit tests. | 24 // Type of crashes generated for the unit tests. |
22 enum RankCrashes { | 25 enum RankCrashes { |
23 NO_CRASH = 0, | 26 NO_CRASH = 0, |
24 INSERT_EMPTY_1, | 27 INSERT_EMPTY_1, |
25 INSERT_EMPTY_2, | 28 INSERT_EMPTY_2, |
26 INSERT_EMPTY_3, | 29 INSERT_EMPTY_3, |
27 INSERT_ONE_1, | 30 INSERT_ONE_1, |
28 INSERT_ONE_2, | 31 INSERT_ONE_2, |
29 INSERT_ONE_3, | 32 INSERT_ONE_3, |
(...skipping 172 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
202 BackendImpl* backend_; | 205 BackendImpl* backend_; |
203 LruData* control_data_; // Data related to the LRU lists. | 206 LruData* control_data_; // Data related to the LRU lists. |
204 IteratorList iterators_; | 207 IteratorList iterators_; |
205 | 208 |
206 DISALLOW_COPY_AND_ASSIGN(Rankings); | 209 DISALLOW_COPY_AND_ASSIGN(Rankings); |
207 }; | 210 }; |
208 | 211 |
209 } // namespace disk_cache | 212 } // namespace disk_cache |
210 | 213 |
211 #endif // NET_DISK_CACHE_RANKINGS_H_ | 214 #endif // NET_DISK_CACHE_RANKINGS_H_ |
OLD | NEW |