summaryrefslogtreecommitdiff
path: root/doc/appfw_resource_manager_doc.h
blob: 1e6375c24405d4a2c52b570f22c79fa7baec3576 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
/*
 * Copyright (c) 2015 - 2016 Samsung Electronics Co., Ltd All Rights Reserved
 *
 * Licensed under the Apache License, Version 2.0 (the License);
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 * http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an AS IS BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

#ifndef __TIZEN_APPFW_APP_RESOURCE_MANAGER_DOC_H__
#define __TIZEN_APPFW_APP_RESOURCE_MANAGER_DOC_H__

/**
 * @ingroup CAPI_APPLICATION_MODULE
 * @defgroup CAPI_RESOURCE_MANAGER_MODULE Resource Manager
 * @brief The @ref CAPI_RESOURCE_MANAGER_MODULE API provides functions to get/set the common resource for multiple devices.
 * @section CAPI_RESOURCE_MANAGER_MODULE_HEADER Required Header
 * \#include <app_resource_manager.h>
 *
 * @section CAPI_RESOURCE_MANAGER_MODULE_OVERVIEW Overview
 * The @ref CAPI_RESOURCE_MANAGER_MODULE API provides functions to use different resources(images, layout, sounds) between each device having different device specifications.
 * For example, if you want to change button image of the application depending on the device's current language setting, put resource files into different folders which are managed by SDK as the same filename.
 * Then call app_resource_manager_get() with resource ID described below to get the appropriate resource filepath, then OS will choose resources for specific devices.
 * You should get the path of the resource file that is managed by the resource manager with app_resource_manager_get() API.
 * Tizen may remove unnecessary resource files for a certain device, so you may fail to access if you access the resource file with the path that is not received with app_resource_manager_get() API.
 * Make sure app_resource_manager_init() should be called first and app_resource_manager_release should be called after using resource manager.
 *
 * @section CAPI_RESOURCE_MANAGER_MODULE_RESOURCE_ID Resource ID
 * Resource ID is an identifier for specific resource. It consists of sub directories and filename including its extension.
 * Same resources are located at different locations with same filename for supporting multiple devices.
 * If you want to get actual filename with given resourceID, refer app_resource_manager_get().
 *
 * @section CAPI_RESOURCE_MANAGER_MODULE_RESOURCE_TYPE Resource Type
 * For now, 4 resource types are supported.
 * Resource which has same resource type are grouped as folder.
 * Folder name is irrelevant with its actual resource type.
 * The managed folders for each type will be generated by SDK tools.
 * In source codes, you can use resource types listed below.
 * (Types will be added for further needs)
 * <table>
 * <tr>
 * <th>TYPE</th>
 * <th>Description</th>
 * </tr>
 * <tr>
 * <td>RSC_TYPE_IMAGE</td>
 * <td>Image resources.</td>
 * </tr>
 * <tr>
 * <td>RSC_TYPE_LAYOUT</td>
 * <td>Application's layout to be displayed.</td>
 * </tr>
 * <tr>
 * <td>RSC_TYPE_SOUND</td>
 * <td>Sound, audio resources.</td>
 * </tr>
 * <tr>
 * <td>RSC_TYPE_BIN</td>
 * <td>All other resources to be needed, but not specified above.</td>
 * </tr>
 * </table>
 *
 * @subsection CAPI_RESOURCE_MANAGER_MODULE_MATCHING_ALGORITHM Matching Algorithm
 *
 * @image html capi_appfw_application_resource.png "Matching Algorithm"
 */

#endif /* __TIZEN_APPFW_APP_RESOURCE_MANAGER_DOC_H__ */