| 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 // This file contains utility functions for dealing with the local | 5 // This file contains utility functions for dealing with the local | 
| 6 // filesystem. | 6 // filesystem. | 
| 7 | 7 | 
| 8 #ifndef BASE_FILE_UTIL_H_ | 8 #ifndef BASE_FILE_UTIL_H_ | 
| 9 #define BASE_FILE_UTIL_H_ | 9 #define BASE_FILE_UTIL_H_ | 
| 10 #pragma once | 10 #pragma once | 
| (...skipping 497 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 508   ~FileEnumerator(); | 508   ~FileEnumerator(); | 
| 509 | 509 | 
| 510   // Returns an empty string if there are no more results. | 510   // Returns an empty string if there are no more results. | 
| 511   FilePath Next(); | 511   FilePath Next(); | 
| 512 | 512 | 
| 513   // Write the file info into |info|. | 513   // Write the file info into |info|. | 
| 514   void GetFindInfo(FindInfo* info); | 514   void GetFindInfo(FindInfo* info); | 
| 515 | 515 | 
| 516   // Looks inside a FindInfo and determines if it's a directory. | 516   // Looks inside a FindInfo and determines if it's a directory. | 
| 517   static bool IsDirectory(const FindInfo& info); | 517   static bool IsDirectory(const FindInfo& info); | 
|  | 518   static bool IsLink(const FindInfo& info); | 
| 518 | 519 | 
| 519   static FilePath GetFilename(const FindInfo& find_info); | 520   static FilePath GetFilename(const FindInfo& find_info); | 
| 520   static int64 GetFilesize(const FindInfo& find_info); | 521   static int64 GetFilesize(const FindInfo& find_info); | 
| 521   static base::Time GetLastModifiedTime(const FindInfo& find_info); | 522   static base::Time GetLastModifiedTime(const FindInfo& find_info); | 
| 522 | 523 | 
| 523  private: | 524  private: | 
| 524   // Returns true if the given path should be skipped in enumeration. | 525   // Returns true if the given path should be skipped in enumeration. | 
| 525   bool ShouldSkip(const FilePath& path); | 526   bool ShouldSkip(const FilePath& path); | 
| 526 | 527 | 
| 527 | 528 | 
| (...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 639 | 640 | 
| 640 }  // namespace file_util | 641 }  // namespace file_util | 
| 641 | 642 | 
| 642 #if defined(OS_WIN) | 643 #if defined(OS_WIN) | 
| 643 // Deprecated functions have been moved to this separate header file, | 644 // Deprecated functions have been moved to this separate header file, | 
| 644 // which must be included last after all the above definitions. | 645 // which must be included last after all the above definitions. | 
| 645 #include "base/file_util_deprecated.h" | 646 #include "base/file_util_deprecated.h" | 
| 646 #endif | 647 #endif | 
| 647 | 648 | 
| 648 #endif  // BASE_FILE_UTIL_H_ | 649 #endif  // BASE_FILE_UTIL_H_ | 
| OLD | NEW | 
|---|