• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
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 #include "data_sync_const.h"
17 #include "media_column.h"
18 #include "medialibrary_db_const.h"
19 #include "photo_album_column.h"
20 #include "photo_map_column.h"
21 
22 
23 namespace OHOS::FileManagement::CloudSync {
24 // PhotoAlbum table
25 const std::string DataSyncConst::ALBUM_TABLE_NAME = "PhotoAlbum";
26 const std::string DataSyncConst::ALBUM_ID = "album_id";
27 const std::string DataSyncConst::ALBUM_TYPE = "album_type";
28 const std::string DataSyncConst::ALBUM_SUBTYPE = "album_subtype";
29 const std::string DataSyncConst::ALBUM_NAME = "album_name";
30 const std::string DataSyncConst::ALBUM_COVER_URI = "cover_uri";
31 const std::string DataSyncConst::ALBUM_COUNT = "count";
32 const std::string DataSyncConst::ALBUM_DATE_MODIFIED = "date_modified";
33 // For api9 compatibility
34 const std::string DataSyncConst::ALBUM_RELATIVE_PATH = "relative_path";
35 // default fetch columns
36 const std::set<std::string> DataSyncConst::DEFAULT_FETCH_COLUMNS = {
37     ALBUM_ID, ALBUM_TYPE, ALBUM_SUBTYPE, ALBUM_NAME, ALBUM_COVER_URI, ALBUM_COUNT
38 };
39 
40 const std::string DataSyncConst::ALBUM_URI_PREFIX = Media::PhotoAlbumColumns::ALBUM_URI_PREFIX;
41 const std::string DataSyncConst::PHOTO_URI_PREFIX = Media::PhotoColumn::PHOTO_URI_PREFIX;
42 
43 const std::string DataSyncConst::INVALID_ID = "0";
44 } // namespace OHOS::FileManagement::CloudSync