From 22987d7a17c8cebcb5c5d51c2b29451c8b7e179c Mon Sep 17 00:00:00 2001 From: Semun Lee Date: Mon, 1 Aug 2016 14:31:16 +0900 Subject: [PATCH] Fix policy for application's shared/data directory Change-Id: Id9bc499370e3397fc6f246ddd5cba92a41eeeb68 Signed-off-by: Semun Lee --- include/app_manager.h | 23 ++++++----------------- 1 file changed, 6 insertions(+), 17 deletions(-) diff --git a/include/app_manager.h b/include/app_manager.h index 1000f49..2ffad50 100644 --- a/include/app_manager.h +++ b/include/app_manager.h @@ -313,24 +313,13 @@ int app_manager_foreach_app_info(app_manager_app_info_cb callback, void *user_da int app_manager_get_app_info(const char *app_id, app_info_h *app_info); /** - * @deprecated Deprecated since 3.0. * @brief Gets the absolute path to the shared data directory of the application specified * with an application ID. * @details An application can only read the files of other application's shared data directory. * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif - * @remarks The specified @a path should be released. @n - * shared/data directory is not supported since Tizen 3.0. - * You MUST NOT use this API when you develop new application. - * Actually, we strongly recommend to stop using shared/data path for all your previous applications. - * Files in shared/data directory can be read by all other applications. - * You cannot control what applications can read the files in shared/data directory. - * If you want to share files with other applications, consider passing path via @ref CAPI_APP_CONTROL_MODULE API. - * The @ref CAPI_APP_CONTROL_MODULE API supports giving permission to other applications by passing path via app_control. @n - * shared/data directory is only available for applications with api-version lower than 3.0 from Tizen 3.0 platform. - * The applications with api-version from 3.0 cannot access other applications' shared/data directory. - * For example, a Tizen @if Mobile 2.4 @elseif WEARABLE 2.3.1 @endif application can access another Tizen @if Mobile 2.4 @elseif WEARABLE 2.3.1 @endif application's shared/data directory as it did in Tizen @if Mobile 2.4 @elseif WEARABLE 2.3.1 @endif platform. - * However, a Tizen 3.0 application cannot access another application's shared/data directory even the another application is Tizen @if Mobile 2.4 @elseif WEARABLE 2.3.1 @endif application. - * Note that Tizen 3.0 platform only supports share/data directory among applications with api-version lower than 3.0 for minimum backward compatibility. + * @remarks The specified @a path should be released with free(). @n + * Since Tizen 3.0, the shared/data directory is supported only for the applications that declare the http://tizen.org/privilege/appdir.shareddata privilege. + * The function will fail with #APP_MANAGER_ERROR_NOT_SUPPORTED if the privilege is not declared. * * @param[in] app_id The ID of the application * @param[in,out] path The absolute path to the shared data directory of the application @@ -350,7 +339,7 @@ int app_manager_get_shared_data_path(const char *app_id, char **path); * with an application ID. * @details An application can only read the files of other application's shared resource directory. * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif - * @remarks The specified @a path should be released. + * @remarks The specified @a path should be released with free(). * * @param[in] app_id The ID of the application * @param[in,out] path The absolute path to the shared resource directory of the application @@ -370,7 +359,7 @@ int app_manager_get_shared_resource_path(const char *app_id, char **path); * @details An application signed with the same certificate can read and write the files of * other application's shared trusted directory. * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif - * @remarks The specified @a path should be released. + * @remarks The specified @a path should be released with free(). * * @param[in] app_id The ID of the application * @param[in,out] path The absolute path to the shared trusted directory of the application @@ -390,7 +379,7 @@ int app_manager_get_shared_trusted_path(const char *app_id, char **path); * with an application ID. * @details An application can only read the files of other application's shared data directory. * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif - * @remarks The specified @a path should be released. + * @remarks The specified @a path should be released with free(). * @remarks To access the path returned by this function may not work as intended in certain devices due to some implementation issues. * * @param[in] app_id The ID of the application -- 2.7.4