cache_util.h revision c7f5f8508d98d5952d42ed7648c2a8f30a4da156
1// Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. 2// Use of this source code is governed by a BSD-style license that can be 3// found in the LICENSE file. 4 5#ifndef NET_DISK_CACHE_CACHE_UTIL_H_ 6#define NET_DISK_CACHE_CACHE_UTIL_H_ 7 8#include <string> 9 10#include "base/basictypes.h" 11 12class FilePath; 13 14namespace disk_cache { 15 16// Moves the cache files from the given path to another location. 17// Returns true if successful, false otherwise. 18bool MoveCache(const FilePath& from_path, const FilePath& to_path); 19 20// Deletes the cache files stored on |path|, and optionally also attempts to 21// delete the folder itself. 22void DeleteCache(const FilePath& path, bool remove_folder); 23 24// Deletes a cache file. 25bool DeleteCacheFile(const FilePath& name); 26 27} // namespace disk_cache 28 29#endif // NET_DISK_CACHE_CACHE_UTIL_H_ 30