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

Side by Side Diff: base/test_file_util.h

Issue 9639: Port flush_cache tool. (Closed) Base URL: http://src.chromium.org/svn/trunk/src/
Patch Set: '' Created 12 years 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 | Annotate | Revision Log
« no previous file with comments | « base/base_lib.scons ('k') | base/test_file_util_linux.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) 2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2008 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 BASE_TEST_FILE_UTIL_H_ 5 #ifndef BASE_TEST_FILE_UTIL_H_
6 #define BASE_TEST_FILE_UTIL_H_ 6 #define BASE_TEST_FILE_UTIL_H_
7 7
8 // File utility functions used only by tests. 8 // File utility functions used only by tests.
9 9
10 #include <string> 10 #include <string>
11 11
12 class FilePath;
13
12 namespace file_util { 14 namespace file_util {
13 15
14 // Clear a specific file from the system cache. After this call, trying 16 // Clear a specific file from the system cache. After this call, trying
15 // to access this file will result in a cold load from the hard drive. 17 // to access this file will result in a cold load from the hard drive.
16 bool EvictFileFromSystemCache(const wchar_t* file); 18 bool EvictFileFromSystemCache(const FilePath& file);
17 19
18 // Like CopyFileNoCache but recursively copies all files and subdirectories 20 // Like CopyFileNoCache but recursively copies all files and subdirectories
19 // in the given input directory to the output directory. Any files in the 21 // in the given input directory to the output directory. Any files in the
20 // destination that already exist will be overwritten. 22 // destination that already exist will be overwritten.
21 // 23 //
22 // Returns true on success. False means there was some error copying, so the 24 // Returns true on success. False means there was some error copying, so the
23 // state of the destination is unknown. 25 // state of the destination is unknown.
24 bool CopyRecursiveDirNoCache(const std::wstring& source_dir, 26 bool CopyRecursiveDirNoCache(const std::wstring& source_dir,
25 const std::wstring& dest_dir); 27 const std::wstring& dest_dir);
26 28
27 } // namespace file_util 29 } // namespace file_util
28 30
29 #endif // BASE_TEST_FILE_UTIL_H_ 31 #endif // BASE_TEST_FILE_UTIL_H_
OLDNEW
« no previous file with comments | « base/base_lib.scons ('k') | base/test_file_util_linux.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698