| OLD | NEW |
| 1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. | 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 | 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_PLATFORM_FILE_H_ | 5 #ifndef BASE_PLATFORM_FILE_H_ |
| 6 #define BASE_PLATFORM_FILE_H_ | 6 #define BASE_PLATFORM_FILE_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include "base/basictypes.h" | 9 #include "base/basictypes.h" |
| 10 #include "build/build_config.h" | 10 #include "build/build_config.h" |
| (...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 53 PLATFORM_FILE_ERROR_IN_USE = -2, | 53 PLATFORM_FILE_ERROR_IN_USE = -2, |
| 54 PLATFORM_FILE_ERROR_EXISTS = -3, | 54 PLATFORM_FILE_ERROR_EXISTS = -3, |
| 55 PLATFORM_FILE_ERROR_NOT_FOUND = -4, | 55 PLATFORM_FILE_ERROR_NOT_FOUND = -4, |
| 56 PLATFORM_FILE_ERROR_ACCESS_DENIED = -5, | 56 PLATFORM_FILE_ERROR_ACCESS_DENIED = -5, |
| 57 PLATFORM_FILE_ERROR_TOO_MANY_OPENED = -6, | 57 PLATFORM_FILE_ERROR_TOO_MANY_OPENED = -6, |
| 58 PLATFORM_FILE_ERROR_NO_MEMORY = -7, | 58 PLATFORM_FILE_ERROR_NO_MEMORY = -7, |
| 59 PLATFORM_FILE_ERROR_NO_SPACE = -8, | 59 PLATFORM_FILE_ERROR_NO_SPACE = -8, |
| 60 PLATFORM_FILE_ERROR_NOT_A_DIRECTORY = -9, | 60 PLATFORM_FILE_ERROR_NOT_A_DIRECTORY = -9, |
| 61 PLATFORM_FILE_ERROR_INVALID_OPERATION = -10, | 61 PLATFORM_FILE_ERROR_INVALID_OPERATION = -10, |
| 62 PLATFORM_FILE_ERROR_SECURITY = -11, | 62 PLATFORM_FILE_ERROR_SECURITY = -11, |
| 63 PLATFORM_FILE_ERROR_ABORT = -12 | 63 PLATFORM_FILE_ERROR_ABORT = -12, |
| 64 PLATFORM_FILE_ERROR_NOT_A_FILE = -13, |
| 65 PLATFORM_FILE_ERROR_NOT_EMPTY = -14, |
| 64 }; | 66 }; |
| 65 | 67 |
| 66 // Used to hold information about a given file. | 68 // Used to hold information about a given file. |
| 67 // If you add more fields to this structure (platform-specific fields are OK), | 69 // If you add more fields to this structure (platform-specific fields are OK), |
| 68 // make sure to update all functions that use it in file_util_{win|posix}.cc | 70 // make sure to update all functions that use it in file_util_{win|posix}.cc |
| 69 // too, and the ParamTraits<base::PlatformFileInfo> implementation in | 71 // too, and the ParamTraits<base::PlatformFileInfo> implementation in |
| 70 // chrome/common/common_param_traits.cc. | 72 // chrome/common/common_param_traits.cc. |
| 71 struct PlatformFileInfo { | 73 struct PlatformFileInfo { |
| 72 // The size of the file in bytes. Undefined when is_directory is true. | 74 // The size of the file in bytes. Undefined when is_directory is true. |
| 73 int64 size; | 75 int64 size; |
| (...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 159 return temp; | 161 return temp; |
| 160 } | 162 } |
| 161 | 163 |
| 162 private: | 164 private: |
| 163 PlatformFile* value_; | 165 PlatformFile* value_; |
| 164 }; | 166 }; |
| 165 | 167 |
| 166 } // namespace base | 168 } // namespace base |
| 167 | 169 |
| 168 #endif // BASE_PLATFORM_FILE_H_ | 170 #endif // BASE_PLATFORM_FILE_H_ |
| OLD | NEW |