| 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 // FilePath is a container for pathnames stored in a platform's native string | 5 // FilePath is a container for pathnames stored in a platform's native string |
| 6 // type, providing containers for manipulation in according with the | 6 // type, providing containers for manipulation in according with the |
| 7 // platform's conventions for pathnames. It supports the following path | 7 // platform's conventions for pathnames. It supports the following path |
| 8 // types: | 8 // types: |
| 9 // | 9 // |
| 10 // POSIX Windows | 10 // POSIX Windows |
| (...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 92 // equivalent. Since the OS treats these paths specially, FilePath needs | 92 // equivalent. Since the OS treats these paths specially, FilePath needs |
| 93 // to do the same. Since Windows can use either / or \ as the separator, | 93 // to do the same. Since Windows can use either / or \ as the separator, |
| 94 // FilePath treats c://, c:\\, //, and \\ all equivalently. | 94 // FilePath treats c://, c:\\, //, and \\ all equivalently. |
| 95 // Reference: | 95 // Reference: |
| 96 // The Old New Thing, "Why is a drive letter permitted in front of UNC | 96 // The Old New Thing, "Why is a drive letter permitted in front of UNC |
| 97 // paths (sometimes)?", available at: | 97 // paths (sometimes)?", available at: |
| 98 // http://blogs.msdn.com/oldnewthing/archive/2005/11/22/495740.aspx | 98 // http://blogs.msdn.com/oldnewthing/archive/2005/11/22/495740.aspx |
| 99 | 99 |
| 100 #ifndef BASE_FILE_PATH_H_ | 100 #ifndef BASE_FILE_PATH_H_ |
| 101 #define BASE_FILE_PATH_H_ | 101 #define BASE_FILE_PATH_H_ |
| 102 #pragma once | |
| 103 | 102 |
| 104 #include <stddef.h> | 103 #include <stddef.h> |
| 105 #include <string> | 104 #include <string> |
| 106 #include <vector> | 105 #include <vector> |
| 107 | 106 |
| 108 #include "base/base_export.h" | 107 #include "base/base_export.h" |
| 109 #include "base/compiler_specific.h" | 108 #include "base/compiler_specific.h" |
| 110 #include "base/hash_tables.h" | 109 #include "base/hash_tables.h" |
| 111 #include "base/string16.h" | 110 #include "base/string16.h" |
| 112 #include "base/string_piece.h" // For implicit conversions. | 111 #include "base/string_piece.h" // For implicit conversions. |
| (...skipping 312 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 425 | 424 |
| 426 inline size_t hash_value(const FilePath& f) { | 425 inline size_t hash_value(const FilePath& f) { |
| 427 return hash_value(f.value()); | 426 return hash_value(f.value()); |
| 428 } | 427 } |
| 429 | 428 |
| 430 #endif // COMPILER | 429 #endif // COMPILER |
| 431 | 430 |
| 432 } // namespace BASE_HASH_NAMESPACE | 431 } // namespace BASE_HASH_NAMESPACE |
| 433 | 432 |
| 434 #endif // BASE_FILE_PATH_H_ | 433 #endif // BASE_FILE_PATH_H_ |
| OLD | NEW |