OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 // The cache is stored on disk as a collection of block-files, plus an index | 5 // The cache is stored on disk as a collection of block-files, plus an index |
6 // file plus a collection of external files. | 6 // file plus a collection of external files. |
7 // | 7 // |
8 // Any data blob bigger than kMaxBlockSize (net/addr.h) will be stored on a | 8 // Any data blob bigger than kMaxBlockSize (net/addr.h) will be stored on a |
9 // separate file named f_xxx where x is a hexadecimal number. Shorter data will | 9 // separate file named f_xxx where x is a hexadecimal number. Shorter data will |
10 // be stored as a series of blocks on a block-file. In any case, CacheAddr | 10 // be stored as a series of blocks on a block-file. In any case, CacheAddr |
(...skipping 242 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
253 }; | 253 }; |
254 | 254 |
255 // The number of blocks stored by a child entry. | 255 // The number of blocks stored by a child entry. |
256 const int kNumSparseBits = 1024; | 256 const int kNumSparseBits = 1024; |
257 COMPILE_ASSERT(sizeof(SparseData) == sizeof(SparseHeader) + kNumSparseBits / 8, | 257 COMPILE_ASSERT(sizeof(SparseData) == sizeof(SparseHeader) + kNumSparseBits / 8, |
258 Invalid_SparseData_bitmap); | 258 Invalid_SparseData_bitmap); |
259 | 259 |
260 } // namespace disk_cache | 260 } // namespace disk_cache |
261 | 261 |
262 #endif // NET_DISK_CACHE_DISK_FORMAT_H_ | 262 #endif // NET_DISK_CACHE_DISK_FORMAT_H_ |
OLD | NEW |