• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (c) 2023-2024 Huawei Device Co., Ltd.
3  * Licensed under the Apache License, Version 2.0 (the "License");
4  * you may not use this file except in compliance with the License.
5  * You may obtain a copy of the License at
6  *
7  *     http://www.apache.org/licenses/LICENSE-2.0
8  *
9  * Unless required by applicable law or agreed to in writing, software
10  * distributed under the License is distributed on an "AS IS" BASIS,
11  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12  * See the License for the specific language governing permissions and
13  * limitations under the License.
14  */
15 
16 #ifndef OHOS_CLOUD_DISK_SERVICE_FILE_COLUMN_H
17 #define OHOS_CLOUD_DISK_SERVICE_FILE_COLUMN_H
18 
19 #include <vector>
20 
21 #include "clouddisk_db_const.h"
22 
23 namespace OHOS {
24 namespace FileManagement {
25 namespace CloudDisk {
26 class FileColumn {
27 public:
28     // Local And Cloud
29     static const std::string CLOUD_ID;
30     static const std::string IS_DIRECTORY;
31     static const std::string FILE_NAME;
32     static const std::string PARENT_CLOUD_ID;
33     static const std::string FILE_SIZE;
34     static const std::string FILE_SHA256;
35     static const std::string FILE_TIME_ADDED;
36     static const std::string FILE_TIME_EDITED;
37     static const std::string FILE_TIME_RECYCLED;
38     static const std::string META_TIME_EDITED;
39     static const std::string DIRECTLY_RECYCLED;
40     static const std::string VERSION;
41     static const std::string OPERATE_TYPE;
42     static const std::string FILE_STATUS;
43     static const std::string ROW_ID;
44     static const std::string CHECK_FLAG;
45     static const std::string ROOT_DIRECTORY;
46     static const std::string ATTRIBUTE;
47 
48     // Only Local
49     static const std::string FILE_TIME_VISIT;
50     static const std::string SYNC_STATUS;
51     static const std::string POSITION;
52     static const std::string DIRTY_TYPE;
53     static const std::string THM_FLAG;
54     static const std::string LCD_FLAG;
55     static const std::string MIME_TYPE;
56     static const std::string FILE_TYPE;
57     static const std::string FILE_CATEGORY;
58     static const std::string IS_FAVORITE;
59     static const std::string NO_NEED_UPLOAD;
60     static const std::string SRC_CLOUD_ID;
61 
62     // table name
63     static const std::string FILES_TABLE;
64 
65     // parentCloudId index
66     static const std::string PARENT_CLOUD_ID_INDEX;
67 
68     // create FileTable sql
69     static const std::string CREATE_FILE_TABLE;
70 
71     // create parentCloudId index
72     static const std::string CREATE_PARENT_CLOUD_ID_INDEX;
73 
74     //create IsFavorite
75     static const std::string ADD_IS_FAVORITE;
76 
77     //create FileStatus
78     static const std::string ADD_FILE_STATUS;
79 
80     //set FileStatus
81     static const std::string SET_FILE_STATUS_DEFAULT;
82 
83     //set CheckFlag
84     static const std::string ADD_CHECK_FLAG;
85 
86     // set attribute
87     static const std::string ADD_ATTRIBUTE;
88 
89     static const std::string ADD_THM_FLAG;
90 
91     static const std::string ADD_LCD_FLAG;
92 
93     static const std::string ADD_UPLOAD_FLAG;
94 
95     // Add copy field
96     static const std::string ADD_SRC_CLOUD_ID;
97 
98     // Query FILES_TABLE for FileSystem
99     static const std::vector<std::string> FILE_SYSTEM_QUERY_COLUMNS;
100 
101     // Query FILES_TABLE for Disk Push
102     static const std::vector<std::string> DISK_CLOUD_SYNC_COLUMNS;
103 
104     static const std::vector<std::string> LOCAL_COLUMNS;
105 
106     // Query pull info columns
107     static const std::vector<std::string> PULL_QUERY_COLUMNS;
108 
109     // Query local info columns
110     static const std::vector<std::string> DISK_ON_UPLOAD_COLUMNS;
111 
112     static const std::vector<std::string> EXT_ATTR_QUERY_COLUMNS;
113 
114     // Query FILES_TABLE for CopyFile
115     static const std::vector<std::string> DISK_CLOUD_FOR_COPY;
116 };
117 } // namespace CloudDisk
118 } // namespace FileManagement
119 } // namespace OHOS
120 #endif // OHOS_CLOUD_DISK_SERVICE_FILE_COLUMN_H