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 | 5 |
6 /* From ppb_file_system.idl modified Wed Oct 5 14:06:02 2011. */ | 6 /* From ppb_file_system.idl modified Wed Feb 15 13:55:58 2012. */ |
7 | 7 |
8 #ifndef PPAPI_C_PPB_FILE_SYSTEM_H_ | 8 #ifndef PPAPI_C_PPB_FILE_SYSTEM_H_ |
9 #define PPAPI_C_PPB_FILE_SYSTEM_H_ | 9 #define PPAPI_C_PPB_FILE_SYSTEM_H_ |
10 | 10 |
11 #include "ppapi/c/pp_bool.h" | 11 #include "ppapi/c/pp_bool.h" |
12 #include "ppapi/c/pp_completion_callback.h" | 12 #include "ppapi/c/pp_completion_callback.h" |
13 #include "ppapi/c/pp_file_info.h" | 13 #include "ppapi/c/pp_file_info.h" |
14 #include "ppapi/c/pp_instance.h" | 14 #include "ppapi/c/pp_instance.h" |
15 #include "ppapi/c/pp_macros.h" | 15 #include "ppapi/c/pp_macros.h" |
16 #include "ppapi/c/pp_resource.h" | 16 #include "ppapi/c/pp_resource.h" |
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
60 * Open() opens the file system. A file system must be opened before running | 60 * Open() opens the file system. A file system must be opened before running |
61 * any other operation on it. | 61 * any other operation on it. |
62 * | 62 * |
63 * @param[in] file_system A <code>PP_Resource</code> corresponding to a file | 63 * @param[in] file_system A <code>PP_Resource</code> corresponding to a file |
64 * system. | 64 * system. |
65 * @param[in] expected_size The expected size of the file system. | 65 * @param[in] expected_size The expected size of the file system. |
66 * @param[in] callback A <code>PP_CompletionCallback</code> to be called upon | 66 * @param[in] callback A <code>PP_CompletionCallback</code> to be called upon |
67 * completion of Open(). | 67 * completion of Open(). |
68 * | 68 * |
69 * @return An int32_t containing an error code from <code>pp_errors.h</code>. | 69 * @return An int32_t containing an error code from <code>pp_errors.h</code>. |
70 * | 70 */ |
| 71 /* |
71 * TODO(brettw) clarify whether this must have completed before a file can | 72 * TODO(brettw) clarify whether this must have completed before a file can |
72 * be opened in it. Clarify what it means to be "completed." | 73 * be opened in it. Clarify what it means to be "completed." |
73 */ | 74 */ |
74 int32_t (*Open)(PP_Resource file_system, | 75 int32_t (*Open)(PP_Resource file_system, |
75 int64_t expected_size, | 76 int64_t expected_size, |
76 struct PP_CompletionCallback callback); | 77 struct PP_CompletionCallback callback); |
77 /** | 78 /** |
78 * GetType() returns the type of the provided file system. | 79 * GetType() returns the type of the provided file system. |
79 * | 80 * |
80 * @param[in] file_system A <code>PP_Resource</code> corresponding to a file | 81 * @param[in] file_system A <code>PP_Resource</code> corresponding to a file |
81 * system. | 82 * system. |
82 * | 83 * |
83 * @return A <code>PP_FileSystemType</code> with the file system type if | 84 * @return A <code>PP_FileSystemType</code> with the file system type if |
84 * valid or <code>PP_FILESYSTEMTYPE_INVALID</code> if the provided resource | 85 * valid or <code>PP_FILESYSTEMTYPE_INVALID</code> if the provided resource |
85 * is not a valid file system. It is valid to call this function even before | 86 * is not a valid file system. It is valid to call this function even before |
86 * Open() completes. | 87 * Open() completes. |
87 */ | 88 */ |
88 PP_FileSystemType (*GetType)(PP_Resource file_system); | 89 PP_FileSystemType (*GetType)(PP_Resource file_system); |
89 }; | 90 }; |
90 | 91 |
91 typedef struct PPB_FileSystem_1_0 PPB_FileSystem; | 92 typedef struct PPB_FileSystem_1_0 PPB_FileSystem; |
92 /** | 93 /** |
93 * @} | 94 * @} |
94 */ | 95 */ |
95 | 96 |
96 #endif /* PPAPI_C_PPB_FILE_SYSTEM_H_ */ | 97 #endif /* PPAPI_C_PPB_FILE_SYSTEM_H_ */ |
97 | 98 |
OLD | NEW |