1 /* 2 * Copyright (c) 2023 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 43 // Only Local 44 static const std::string FILE_TIME_VISIT; 45 static const std::string SYNC_STATUS; 46 static const std::string POSITION; 47 static const std::string DIRTY_TYPE; 48 static const std::string MIME_TYPE; 49 static const std::string FILE_TYPE; 50 static const std::string FILE_CATEGORY; 51 52 // table name 53 static const std::string FILES_TABLE; 54 55 // parentCloudId index 56 static const std::string PARENT_CLOUD_ID_INDEX; 57 58 // create FileTable sql 59 static const std::string CREATE_FILE_TABLE; 60 61 // create parentCloudId index 62 static const std::string CREATE_PARENT_CLOUD_ID_INDEX; 63 64 // Query FILES_TABLE for FileSystem 65 static const std::vector<std::string> FILE_SYSTEM_QUERY_COLUMNS; 66 67 // Query FILES_TABLE for Disk Push 68 static const std::vector<std::string> DISK_CLOUD_SYNC_COLUMNS; 69 70 static const std::vector<std::string> LOCAL_COLUMNS; 71 72 // Query pull info columns 73 static const std::vector<std::string> PULL_QUERY_COLUMNS; 74 75 // Query local info columns 76 static const std::vector<std::string> DISK_ON_UPLOAD_COLUMNS; 77 }; 78 } // namespace CloudDisk 79 } // namespace FileManagement 80 } // namespace OHOS 81 #endif // OHOS_CLOUD_DISK_SERVICE_FILE_COLUMN_H