X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=inc%2FFAppPkgPackageManager.h;h=ee3ce3e2c18845134d0dfaa4a69eedabae42ecbc;hb=20597a73bc3098301ba91a48378f3ef009c3be96;hp=59d24a2359635f34ffca4f1b085875baeb5b01ff;hpb=a139976c28dfb6735f5fa8708903b2a3a86418d8;p=platform%2Fframework%2Fnative%2Fappfw.git diff --git a/inc/FAppPkgPackageManager.h b/inc/FAppPkgPackageManager.h index 59d24a2..ee3ce3e 100755 --- a/inc/FAppPkgPackageManager.h +++ b/inc/FAppPkgPackageManager.h @@ -45,20 +45,20 @@ class IPackageUninstallationResponseListener; */ enum PackageType { - PACKAGE_TYPE_TPK, /**< TIZEN Native package */ - PACKAGE_TYPE_WGT, /**< TIZEN %Web package */ - PACKAGE_TYPE_RPM, /**< TIZEN Core package */ + PACKAGE_TYPE_TPK, /**< %Tizen native package */ + PACKAGE_TYPE_WGT, /**< %Tizen Web package */ + PACKAGE_TYPE_RPM, /**< %Tizen Core package */ }; /** * @class PackageManager - * @brief This class gets the information of packages and manages package installation or uninstallation. + * @brief This class gets the information of a package and manages the package's installation or uninstallation. * * @since 2.0 * * @final This class is not intended for extension. * - * The %PackageManager class provides methods to install or uninstall the packages, retrieves the information of the packages that are installed on the device. + * The %PackageManager class provides methods to install or uninstall a package and retrieve the information of a package that is installed on the device. * * For more information on the class features, see Package Management. * @@ -73,7 +73,8 @@ public: * @since 2.0 * * @return The package ID, @n - * else @c packageId.IsEmtpy() == true is returned if an error occurs + * else an empty package ID if an error occurs @n + * Checks with packageId.IsEmpty() whether the package ID is empty. * @param[in] appId The application ID * @exception E_SUCCESS The method is successful. * @exception E_INVALID_ARG The specified input parameter is invalid. @@ -84,10 +85,10 @@ public: /** * Adds a package installation event listener. * - * @since 2.0 + * @since 2.0 * @privlevel public * @privilege %http://tizen.org/privilege/package.info @n - * (%http://tizen.org/privilege/packageinfo is deprecated.) + * (%http://tizen.org/privilege/packageinfo is deprecated.) * * @return An error code * @param[in] listener The package installation event listener @@ -103,31 +104,33 @@ public: * @since 2.0 * @privlevel public * @privilege %http://tizen.org/privilege/package.info @n - * (%http://tizen.org/privilege/packageinfo is deprecated.) + * (%http://tizen.org/privilege/packageinfo is deprecated.) * * @return An error code * @param[in] listener The package installation event listener * @exception E_SUCCESS The method is successful. - * @exception E_OBJ_NOT_FOUND The listener is not added or is already removed. + * @exception E_OBJ_NOT_FOUND Either of the following conditions has occurred: + * - The listener is not added. + * - The listener is already removed. * @exception E_PRIVILEGE_DENIED The application does not have the privilege to call this method. */ result RemovePackageInstallationEventListener(IPackageInstallationEventListener& listener); /** - * Gets a package information with the specific package ID. + * Gets the package information with the specific package ID. * * @since 2.0 * @privlevel public * @privilege %http://tizen.org/privilege/package.info @n - * (%http://tizen.org/privilege/packageinfo is deprecated.) + * (%http://tizen.org/privilege/packageinfo is deprecated.) * - * @return A pointer to PackageInfo + * @return A pointer to the PackageInfo instance * @param[in] packageId The package ID - * @exception E_SUCCESS The method is successful. - * @exception E_INVALID_ARG The specified input parameter is invalid. - * @exception E_SYSTEM The method cannot proceed due to a severe system error. - * @exception E_PKG_NOT_INSTALLED The package is not installed. - * @exception E_PRIVILEGE_DENIED The application does not have the privilege to call this method. + * @exception E_SUCCESS The method is successful. + * @exception E_INVALID_ARG The specified input parameter is invalid. + * @exception E_SYSTEM The method cannot proceed due to a severe system error. + * @exception E_PKG_NOT_INSTALLED The package has not been installed. + * @exception E_PRIVILEGE_DENIED The application does not have the privilege to call this method. * @remarks The specific error code can be accessed using the GetLastResult() method. */ PackageInfo* GetPackageInfoN(const PackageId& packageId) const; @@ -138,9 +141,9 @@ public: * @since 2.0 * @privlevel public * @privilege %http://tizen.org/privilege/package.info @n - * (%http://tizen.org/privilege/packageinfo is deprecated.) + * (%http://tizen.org/privilege/packageinfo is deprecated.) * - * @return A pointer to PackageAppInfo + * @return A pointer to the PackageAppInfo instance * @param[in] appId The application ID * @exception E_SUCCESS The method is successful. * @exception E_INVALID_ARG The specified input parameter is invalid. @@ -156,7 +159,7 @@ public: * @since 2.0 * @privlevel public * @privilege %http://tizen.org/privilege/package.info @n - * (%http://tizen.org/privilege/packageinfo is deprecated.) + * (%http://tizen.org/privilege/packageinfo is deprecated.) * * @return A pointer to the list of the PackageInfo instances, @n * else @c null if it fails @@ -173,11 +176,11 @@ public: * @since 2.0 * @privlevel public * @privilege %http://tizen.org/privilege/package.info @n - * (%http://tizen.org/privilege/packageinfo is deprecated.) + * (%http://tizen.org/privilege/packageinfo is deprecated.) * - * @return @c true if a package is installed, @n - * else @c false - * @param[in] packageId The package ID + * @return @c true if the package is installed, @n + * else @c false + * @param[in] packageId The package ID * @exception E_SUCCESS The method is successful. * @exception E_INVALID_ARG The specified input parameter is invalid. * @exception E_SYSTEM The method cannot proceed due to a severe system error. @@ -188,7 +191,8 @@ public: /** * Installs a package. @n - * The %InstallPackage() method operates asynchronously, that is, it ends immediately without an installation response. The application is notified when the installation is completed, so the response is available through the IPackageInstallationResponseListener::OnPackageInstallationCompleted() method, if this method returns @c E_SUCCESS. + * The %InstallPackage() method operates asynchronously, that is, it ends immediately without an installation response. + * The application is notified when the installation is completed, so the response is available through the IPackageInstallationResponseListener::OnPackageInstallationCompleted() method, if this method returns @c E_SUCCESS. * * @since 2.0 * @privlevel platform @@ -202,13 +206,17 @@ public: * @exception E_INVALID_ARG A specified input parameter is invalid. * @exception E_SYSTEM The method cannot proceed due to a severe system error. * @exception E_PRIVILEGE_DENIED The application does not have the privilege to call this method. - * @remarks A listener instance ownership is transferred to the platform. After notifying result, the listener instance is removed automatically. A reuse of the listener instance is not allowed. + * @remarks + * - A listener instance ownership is transferred to the platform. + * - After notifying the result, the listener instance is removed automatically. + * - A reuse of the listener instance is not allowed. */ result InstallPackage(const PackageId& packageId, const Tizen::Base::String& packagePath, IPackageInstallationResponseListener* pListener); /** * Uninstalls a package with the specified package ID. @n - * The %UninstallPackage() method operates asynchronously, that is, it ends immediately without an uninstallation response. The application is notified when the uninstallation is completed, so the response is available through the IPackageUninstallationResponseListener::OnPackageUninstallationCompleted() method, if this method returns @c true. + * The %UninstallPackage() method operates asynchronously, that is, it ends immediately without an uninstallation response. + * The application is notified when the uninstallation is completed, so the response is available through the IPackageUninstallationResponseListener::OnPackageUninstallationCompleted() method, if this method returns @c true. * * @since 2.0 * @privlevel platform @@ -220,74 +228,78 @@ public: * @exception E_SUCCESS The method is successful. * @exception E_INVALID_ARG A specified input parameter is invalid. * @exception E_SYSTEM The method cannot proceed due to a severe system error. - * @exception E_PKG_NOT_INSTALLED The package is not installed. + * @exception E_PKG_NOT_INSTALLED The package has not been installed. * @exception E_PRIVILEGE_DENIED The application does not have the privilege to call this method. - * @remarks A listener instance ownership is transferred to the platform. After notifying result, the listener instance is removed automatically. A reuse of the listener instance is not allowed. + * @remarks + * - A listener instance ownership is transferred to the platform. + * - After notifying the result, the listener instance is removed automatically. + * - A reuse of the listener instance is not allowed. */ result UninstallPackage(const PackageId& packageId, IPackageUninstallationResponseListener* pListener); /** - * Moves a package with the specified package ID to an external storage. + * Moves a package with the specified package ID to the external storage. * - * @since 2.0 + * @since 2.0 * @privlevel platform * @privilege %http://tizen.org/privilege/packagemanager.setting @n - * (%http://tizen.org/privilege/packagesetting is deprecated.) + * (%http://tizen.org/privilege/packagesetting is deprecated.) * * @return An error code * @param[in] packageId The package ID * @exception E_SUCCESS The method is successful. * @exception E_INVALID_ARG The specified input parameter is invalid. - * @exception E_INVALID_OPERATION The package is already installed in an external storage. + * @exception E_INVALID_OPERATION The package is already installed in the external storage. * @exception E_STORAGE_FULL The storage is full. - * @exception E_PKG_NOT_INSTALLED The package is not installed. + * @exception E_PKG_NOT_INSTALLED The package has not been installed. * @exception E_SYSTEM The method cannot proceed due to a severe system error. * @exception E_PRIVILEGE_DENIED The application does not have the privilege to call this method. */ result MoveToExternalStorage(const PackageId& packageId); /** - * Moves a package with the specified package ID to an internal storage. + * Moves a package with the specified package ID to the internal storage. * - * @since 2.0 + * @since 2.0 * @privlevel platform * @privilege %http://tizen.org/privilege/packagemanager.setting @n - * (%http://tizen.org/privilege/packagesetting is deprecated.) + * (%http://tizen.org/privilege/packagesetting is deprecated.) * * @return An error code * @param[in] packageId The package ID * @exception E_SUCCESS The method is successful. * @exception E_INVALID_ARG The specified input parameter is invalid. - * @exception E_INVALID_OPERATION The package is already installed in an internal storage. + * @exception E_INVALID_OPERATION The package is already installed in the internal storage. * @exception E_STORAGE_FULL The storage is full. - * @exception E_PKG_NOT_INSTALLED The package is not installed. + * @exception E_PKG_NOT_INSTALLED The package has not been installed. * @exception E_SYSTEM The method cannot proceed due to a severe system error. * @exception E_PRIVILEGE_DENIED The application does not have the privilege to call this method. */ result MoveToInternalStorage(const PackageId& packageId); /** - * Gets a package information from a specific file. @n The supported file extensions are tpk and wgt. + * Gets the package information from a specific file. @n + * The supported file extensions are tpk and wgt. * * @since 2.1 * @privlevel platform * @privilege %http://tizen.org/privilege/packagemanager.info * * @return A pointer to the PackageInfo instance, @n - * else @c null if it fails - * @param[in] filePath The package file path - * @exception E_SUCCESS The method is successful. - * @exception E_INVALID_ARG The specified input parameter is invalid. - * @exception E_FILE_NOT_FOUND The specified file cannot be found or accessed. - * @exception E_UNSUPPORTED_FORMAT The specified format is invalid or not supported. - * @exception E_PARSING_FAILED The method has failed to parse the package file or xml file(s) inside the package. - * @exception E_PRIVILEGE_DENIED The application does not have the privilege to call this method. - * @remarks The specific error code can be accessed using the GetLastResult() method. + * else @c null if it fails + * @param[in] filePath The package file path + * @exception E_SUCCESS The method is successful. + * @exception E_INVALID_ARG The specified input parameter is invalid. + * @exception E_FILE_NOT_FOUND The specified file cannot be found or accessed. + * @exception E_UNSUPPORTED_FORMAT The specified format is invalid or not supported. + * @exception E_PARSING_FAILED The method has failed to parse the package file or xml file(s) inside the package. + * @exception E_PRIVILEGE_DENIED The application does not have the privilege to call this method. + * @remarks The specific error code can be accessed using the GetLastResult() method. */ PackageInfo* GetPackageInfoFromFileN(const Tizen::Base::String& filePath) const; /** - * Gets the package information list with the package filter. + * Gets the package information list using the package filter. * * @since 2.1 * @privlevel public @@ -296,18 +308,18 @@ public: * @return A pointer to the list of the PackageInfo instances, @n * else @c null if it fails * @param[in] packageFilterMap The predefined key(Tizen::Base::String)-value(Tizen::Base::Boolean) pairs for the package filter @n - * For more information on the predefined key-value pairs for package filter, - * see the predefined key-value pairs for package filter. - * @exception E_SUCCESS The method is successful. - * @exception E_INVALID_ARG The specified input parameter is invalid. - * @exception E_SYSTEM The method cannot proceed due to a severe system error. - * @exception E_PRIVILEGE_DENIED The application does not have the privilege to call this method. + * For more information on the predefined key-value pairs for the package filter, + * see the predefined key-value pairs for the package filter. + * @exception E_SUCCESS The method is successful. + * @exception E_INVALID_ARG The specified input parameter is invalid. + * @exception E_SYSTEM The method cannot proceed due to a severe system error. + * @exception E_PRIVILEGE_DENIED The application does not have the privilege to call this method. * @remarks The specific error code can be accessed using the GetLastResult() method. */ Tizen::Base::Collection::IList* GetPackageInfoListN(const Tizen::Base::Collection::IMap& packageFilterMap) const; /** - * Gets the application information list with the package app filter. + * Gets the application information list using the package application filter. * * @since 2.1 * @privlevel public @@ -315,47 +327,47 @@ public: * * @return A pointer to the list of the PackageAppInfo instances, @n * else @c null if it fails - * @param[in] packageAppFilterMap The predefined key(Tizen::Base::String)-value(Tizen::Base::String or Tizen::Base::Boolean) pairs for the package app filter @n - * For more information, see - * the predefined key-value pairs for package app filter. - * @exception E_SUCCESS The method is successful. - * @exception E_INVALID_ARG The specified input parameter is invalid. - * @exception E_SYSTEM The method cannot proceed due to a severe system error. - * @exception E_PRIVILEGE_DENIED The application does not have the privilege to call this method. + * @param[in] packageAppFilterMap The predefined key(Tizen::Base::String)-value(Tizen::Base::String or Tizen::Base::Boolean) pairs for the package application filter @n + * For more information, see + * the predefined key-value pairs for the package application filter. + * @exception E_SUCCESS The method is successful. + * @exception E_INVALID_ARG The specified input parameter is invalid. + * @exception E_SYSTEM The method cannot proceed due to a severe system error. + * @exception E_PRIVILEGE_DENIED The application does not have the privilege to call this method. * @remarks The specific error code can be accessed using the GetLastResult() method. */ Tizen::Base::Collection::IList* GetPackageAppInfoListN(const Tizen::Base::Collection::IMap& packageAppFilterMap) const; /** - * Gets the application information list with the package filter and package app filter. + * Gets the application information list using the package filter and the package application filter. * * @since 2.1 * @privlevel public * @privilege %http://tizen.org/privilege/package.info * * @return A pointer to the list of the PackageAppInfo instances, @n - * else @c null if it fails + * else @c null if it fails * @param[in] packageFilterMap The predefined key(Tizen::Base::String)-value(Tizen::Base::Boolean) pairs for the package filter @n - * @param[in] packageAppFilterMap The predefined and user defined key(Tizen::Base::String)-value(Tizen::Base::String or Tizen::Base::Boolean) pairs for the package app filter @n - * The user defined key-value pairs can be added in of manifest.xml. @n For more information, - * see the predefined key-value pairs - * for package filter and the - * predefined key-value pairs for package app filter. - * @exception E_SUCCESS The method is successful. - * @exception E_INVALID_ARG A specified input parameter is invalid. - * @exception E_SYSTEM The method cannot proceed due to a severe system error. - * @exception E_PRIVILEGE_DENIED The application does not have the privilege to call this method. + * @param[in] packageAppFilterMap The predefined and user defined key(Tizen::Base::String)-value(%Tizen::Base::String or Tizen::Base::Boolean) pairs for the package application filter @n + * The user defined key-value pairs can be added in the of the manifest.xml. @n For more information, + * see the predefined key-value pairs + * for the package filter, and the + * predefined key-value pairs for the package application filter. + * @exception E_SUCCESS The method is successful. + * @exception E_INVALID_ARG A specified input parameter is invalid. + * @exception E_SYSTEM The method cannot proceed due to a severe system error. + * @exception E_PRIVILEGE_DENIED The application does not have the privilege to call this method. * @remarks The specific error code can be accessed using the GetLastResult() method. */ Tizen::Base::Collection::IList* GetPackageAppInfoListN(const Tizen::Base::Collection::IMap& packageFilterMap, const Tizen::Base::Collection::IMap& packageAppFilterMap) const; /** - * Gets the package manager instance. + * Gets a pointer to the %PackageManager instance. * * @since 2.0 * * @return A pointer to the %PackageManager instance, @n - * else @c null + * else @c null if it fails * @remarks The specific error code can be accessed using the GetLastResult() method. */ static PackageManager* GetInstance(void);