Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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_BLOCK_FILES_H__ | 7 #ifndef NET_DISK_CACHE_BLOCK_FILES_H__ |
| 8 #define NET_DISK_CACHE_BLOCK_FILES_H__ | 8 #define NET_DISK_CACHE_BLOCK_FILES_H__ |
| 9 #pragma once | 9 #pragma once |
| 10 | 10 |
| 11 #include <vector> | 11 #include <vector> |
| 12 | 12 |
| 13 #include "base/file_path.h" | 13 #include "base/file_path.h" |
| 14 #include "base/gtest_prod_util.h" | 14 #include "base/gtest_prod_util.h" |
| 15 #include "base/scoped_ptr.h" | 15 #include "base/scoped_ptr.h" |
| 16 #include "base/threading/thread_checker.h" | |
| 16 #include "net/disk_cache/addr.h" | 17 #include "net/disk_cache/addr.h" |
| 17 #include "net/disk_cache/mapped_file.h" | 18 #include "net/disk_cache/mapped_file.h" |
| 18 | 19 |
| 19 namespace base { | |
| 20 class ThreadChecker; | |
|
brettw
2011/03/03 17:39:43
It kind of sucks we lose the ability to forward de
| |
| 21 } | |
| 22 | |
| 23 namespace disk_cache { | 20 namespace disk_cache { |
| 24 | 21 |
| 25 // This class handles the set of block-files open by the disk cache. | 22 // This class handles the set of block-files open by the disk cache. |
| 26 class BlockFiles { | 23 class BlockFiles { |
| 27 public: | 24 public: |
| 28 explicit BlockFiles(const FilePath& path); | 25 explicit BlockFiles(const FilePath& path); |
| 29 ~BlockFiles(); | 26 ~BlockFiles(); |
| 30 | 27 |
| 31 // Performs the object initialization. create_files indicates if the backing | 28 // Performs the object initialization. create_files indicates if the backing |
| 32 // files should be created or just open. | 29 // files should be created or just open. |
| (...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 94 FRIEND_TEST_ALL_PREFIXES(DiskCacheTest, BlockFiles_ZeroSizeFile); | 91 FRIEND_TEST_ALL_PREFIXES(DiskCacheTest, BlockFiles_ZeroSizeFile); |
| 95 FRIEND_TEST_ALL_PREFIXES(DiskCacheTest, BlockFiles_InvalidFile); | 92 FRIEND_TEST_ALL_PREFIXES(DiskCacheTest, BlockFiles_InvalidFile); |
| 96 FRIEND_TEST_ALL_PREFIXES(DiskCacheTest, BlockFiles_Stats); | 93 FRIEND_TEST_ALL_PREFIXES(DiskCacheTest, BlockFiles_Stats); |
| 97 | 94 |
| 98 DISALLOW_COPY_AND_ASSIGN(BlockFiles); | 95 DISALLOW_COPY_AND_ASSIGN(BlockFiles); |
| 99 }; | 96 }; |
| 100 | 97 |
| 101 } // namespace disk_cache | 98 } // namespace disk_cache |
| 102 | 99 |
| 103 #endif // NET_DISK_CACHE_BLOCK_FILES_H__ | 100 #endif // NET_DISK_CACHE_BLOCK_FILES_H__ |
| OLD | NEW |