Move remaining resources from java_staging/res to java/res.
[chromium-blink-merge.git] / ppapi / c / pp_file_info.h
blob1f0c52a6f705e7e8680a7be3e015d4f9edcb692b
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
3 * found in the LICENSE file.
4 */
6 /* From pp_file_info.idl modified Thu May 2 16:41:50 2013. */
8 #ifndef PPAPI_C_PP_FILE_INFO_H_
9 #define PPAPI_C_PP_FILE_INFO_H_
11 #include "ppapi/c/pp_macros.h"
12 #include "ppapi/c/pp_stdint.h"
13 #include "ppapi/c/pp_time.h"
15 /**
16 * @file
17 * This file defines three enumerations for use in the PPAPI C file IO APIs.
21 /**
22 * @addtogroup Enums
23 * @{
25 /**
26 * The <code>PP_FileType</code> enum contains file type constants.
28 typedef enum {
29 /** A regular file type */
30 PP_FILETYPE_REGULAR = 0,
31 /** A directory */
32 PP_FILETYPE_DIRECTORY = 1,
33 /** A catch-all for unidentified types */
34 PP_FILETYPE_OTHER = 2
35 } PP_FileType;
36 PP_COMPILE_ASSERT_SIZE_IN_BYTES(PP_FileType, 4);
38 /**
39 * The <code>PP_FileSystemType</code> enum contains file system type constants.
41 typedef enum {
42 /** For identified invalid return values */
43 PP_FILESYSTEMTYPE_INVALID = 0,
44 /** For external file system types */
45 PP_FILESYSTEMTYPE_EXTERNAL = 1,
46 /** For local persistent file system types */
47 PP_FILESYSTEMTYPE_LOCALPERSISTENT = 2,
48 /** For local temporary file system types */
49 PP_FILESYSTEMTYPE_LOCALTEMPORARY = 3,
50 /** For isolated file system types */
51 PP_FILESYSTEMTYPE_ISOLATED = 4
52 } PP_FileSystemType;
53 PP_COMPILE_ASSERT_SIZE_IN_BYTES(PP_FileSystemType, 4);
54 /**
55 * @}
58 /**
59 * @addtogroup Structs
60 * @{
62 /**
63 * The <code>PP_FileInfo</code> struct represents all information about a file,
64 * such as size, type, and creation time.
66 struct PP_FileInfo {
67 /** This value represents the size of the file measured in bytes */
68 int64_t size;
69 /**
70 * This value represents the type of file as defined by the
71 * <code>PP_FileType</code> enum
73 PP_FileType type;
74 /**
75 * This value represents the file system type of the file as defined by the
76 * <code>PP_FileSystemType</code> enum.
78 PP_FileSystemType system_type;
79 /**
80 * This value represents the creation time of the file.
82 PP_Time creation_time;
83 /**
84 * This value represents the last time the file was accessed.
86 PP_Time last_access_time;
87 /**
88 * This value represents the last time the file was modified.
90 PP_Time last_modified_time;
92 PP_COMPILE_ASSERT_STRUCT_SIZE_IN_BYTES(PP_FileInfo, 40);
93 /**
94 * @}
97 #endif /* PPAPI_C_PP_FILE_INFO_H_ */