/// <param name="eventType">Event type of the request.</param>
/// <param name="eventState">Current event state of the request.</param>
/// <param name="progress">Progress for the request being processed by the package manager (in percent).</param>
+ /// <remarks>
+ /// The RequestEventCallback function provides information about the current status of a package request. It is called every time there is an update in the package request process. By monitoring the arguments passed to this function, you can keep track of the progress and events related to the package request.
+ /// </remarks>
+ /// <example>
+ /// <code>
+ /// private static void OnRequestEventCallback(string type, string packageId, PackageEventType eventType, PackageEventState eventState, int progress)
+ /// {
+ /// switch (eventType)
+ /// {
+ /// case PackageEventType.Installing:
+ /// Console.WriteLine($"Package '{packageId}' is currently installing.");
+ /// break;
+ /// case PackageEventType.Updating:
+ /// Console.WriteLine($"Package '{packageId}' is currently updating.");
+ /// break;
+ /// case PackageEventType.Removing:
+ /// Console.WriteLine($"Package '{packageId}' is currently removing.");
+ /// break;
+ /// default:
+ /// throw new ArgumentException($"Unknown event type: {eventType}");
+ /// }
+ /// }
+ /// </code>
+ /// </example>
/// <since_tizen> 3 </since_tizen>
public delegate void RequestEventCallback(string type, string packageId, PackageEventType eventType, PackageEventState eventState, int progress);
private delegate Interop.PackageManager.ErrorCode InstallPackagesMethod(SafePackageManagerRequestHandle requestHandle, string[] pkgPaths, int pathsCount, out int requestID);
/// <summary>
- /// InstallProgressChanged event. This event occurs when a package is getting installed and the progress of the request to the package manager is changed.
+ /// InstallProgressChanged event. Occurs when a package is being installed and the progress of the request to the package manager changes.
/// </summary>
- /// <exception cref="IOException">Thrown when subscribing to package manager event failed.</exception>
+ /// <exception cref="IOException">Thrown when subscribing to package manager event fails.</exception>
/// <since_tizen> 3 </since_tizen>
public static event EventHandler<PackageManagerEventArgs> InstallProgressChanged
{
UnregisterPackageManagerEventIfNeeded();
UnsetPackageManagerEventStatus();
}
- }
+ }
}
/// <summary>
/// </summary>
/// <param name="applicationId">The ID of the application.</param>
/// <returns>Returns the ID of the package.</returns>
- /// <remarks>It returns null if the input is null.</remarks>
- /// <exception cref="ArgumentException">Thrown when input application ID does not exist.</exception>
+ /// <remarks>If the input is null, it returns null.</remarks>
+ /// <exception cref="ArgumentException">Thrown when the input application ID does not exist.</exception>
/// <exception cref="OutOfMemoryException">Thrown when there is not enough memory to continue the execution of the method.</exception>
/// <exception cref="UnauthorizedAccessException">Thrown when an application does not have the privilege to access this method.</exception>
/// <privilege>http://tizen.org/privilege/packagemanager.info</privilege>
/// <summary>
/// Clears all the application's internal and external cache directories.
/// </summary>
+ /// <remarks>
+ /// This method clears both the internal and external cache directories of the application. It ensures that any cached files are removed from the device storage.
+ /// By calling this method, you can free up valuable space on the device and improve its performance. However, note that this operation may take some time depending on the amount of cached data present in the directories.
+ /// </remarks>
/// <exception cref="OutOfMemoryException">Thrown when there is not enough memory to continue the execution of the method.</exception>
/// <exception cref="System.IO.IOException">Thrown when the method fails due to an internal IO error.</exception>
/// <exception cref="UnauthorizedAccessException">Thrown when an application does not have the privilege to access this method.</exception>
/// </summary>
/// <remarks>
/// All files under data, shared/data, and shared/trusted in the internal storage are removed.
- /// And, if the external storage exists, then all files under data and shared/trusted in the external storage are removed.
+ /// And, if the external storage exists, then all files under data and shared/trusted in the external storage are also removed.
/// </remarks>
/// <param name="packageId">ID of the package.</param>
/// <exception cref="OutOfMemoryException">Thrown when there is not enough memory to continue the execution of the method.</exception>
- /// <exception cref="System.IO.IOException">Thrown when the method failed due to an internal IO error.</exception>
- /// <exception cref="UnauthorizedAccessException">Thrown when an application does not have the privilege to access this method.</exception>
- /// <exception cref="SystemException">Thrown when the method failed due to an internal system error.</exception>
+ /// <exception cref="System.IO.IOException">Thrown when the method fails due to an internal IO error.</exception>
+ /// <exception cref="UnauthorizedAccessException">Thrown when an application does not have the required privileges to access this method.</exception>
+ /// <exception cref="SystemException">Thrown when the method fails due to an internal system error.</exception>
/// <privilege>http://tizen.org/privilege/packagemanager.admin</privilege>
/// <privlevel>platform</privlevel>
/// <since_tizen> 3 </since_tizen>
/// </summary>
/// <param name="packagePath">Absolute path for the package to be installed.</param>
/// <param name="installMode">Optional parameter to indicate special installation mode.</param>
- /// <returns>Returns true if the installation request is successful, otherwise false.</returns>
+ /// <returns>True if the installation request is successful, otherwise false.</returns>
/// <remarks>
- /// The 'true' means that the request for installation is successful.
- /// To check the result of the installation, the caller should check the progress using the InstallProgressChanged event.
+ /// True indicates that the installation request was successful. However, to determine whether the actual installation was completed successfully, the caller must monitor the progress by subscribing to the InstallProgressChanged event.
/// </remarks>
/// <privilege>http://tizen.org/privilege/packagemanager.admin</privilege>
/// <privlevel>platform</privlevel>
/// <param name="installMode">Optional parameter to indicate special installation mode.</param>
/// <returns>Returns true if installation request is successful, false otherwise.</returns>
/// <remarks>
- /// The 'true' means that the request for installation is successful.
- /// To check the result of installation, the caller should check the progress using the InstallProgressChanged event or eventCallback.
+ /// True indicates that the installation request was successful. However, to determine whether the actual installation was completed successfully, the caller must monitor the progress by subscribing to the InstallProgressChanged event.
/// </remarks>
/// <privilege>http://tizen.org/privilege/packagemanager.admin</privilege>
/// <privlevel>platform</privlevel>
/// <param name="installMode">Optional parameter to indicate special installation mode.</param>
/// <returns>Returns true if installation request is successful, false otherwise.</returns>
/// <remarks>
- /// The 'true' means that the request for installation is successful.
- /// To check the result of installation, the caller should check the progress using the InstallProgressChanged event.
+ /// True indicates that the installation request was successful. However, to determine whether the actual installation was completed successfully, the caller must monitor the progress by subscribing to the InstallProgressChanged event.
/// </remarks>
/// <privilege>http://tizen.org/privilege/packagemanager.admin</privilege>
/// <privlevel>platform</privlevel>
/// <param name="installMode">Optional parameter to indicate special installation mode.</param>
/// <returns>Returns true if installation request is successful, false otherwise.</returns>
/// <remarks>
- /// The 'true' means that the request for installation is successful.
- /// To check the result of installation, the caller should check the progress using the InstallProgressChanged event.
+ /// True indicates that the installation request was successful. However, to determine whether the actual installation was completed successfully, the caller must monitor the progress by subscribing to the InstallProgressChanged event.
/// </remarks>
/// <privilege>http://tizen.org/privilege/packagemanager.admin</privilege>
/// <privlevel>platform</privlevel>
/// <param name="installMode">Optional parameter to indicate special installation mode.</param>
/// <returns>Returns true if installation request is successful, false otherwise.</returns>
/// <remarks>
- /// The 'true' means that the request for installation is successful.
- /// To check the result of installation, the caller should check the progress using the InstallProgressChanged event or eventCallback.
+ /// True indicates that the installation request was successful. However, to determine whether the actual installation was completed successfully, the caller must monitor the progress by subscribing to the InstallProgressChanged event.
/// </remarks>
/// <privilege>http://tizen.org/privilege/packagemanager.admin</privilege>
/// <privlevel>platform</privlevel>
/// <param name="installMode">Optional parameter to indicate special installation mode.</param>
/// <returns>Returns true if installation request is successful, false otherwise.</returns>
/// <remarks>
- /// The 'true' means that the request for installation is successful.
- /// To check the result of installation, the caller should check the progress using the InstallProgressChanged event or eventCallback.
+ /// True indicates that the installation request was successful. However, to determine whether the actual installation was completed successfully, the caller must monitor the progress by subscribing to the InstallProgressChanged event.
/// </remarks>
/// <privilege>http://tizen.org/privilege/packagemanager.admin</privilege>
/// <privlevel>platform</privlevel>
/// <param name="installMode">Optional parameter to indicate special installation mode.</param>
/// <returns>Returns true if installation request is successful, false otherwise.</returns>
/// <remarks>
- /// The 'true' means that the request for installation is successful.
- /// To check the result of installation, the caller should check the progress using the InstallProgressChanged event.
+ /// True indicates that the installation request was successful. However, to determine whether the actual installation was completed successfully, the caller must monitor the progress by subscribing to the InstallProgressChanged event.
/// </remarks>
/// <privilege>http://tizen.org/privilege/packagemanager.admin</privilege>
/// <privlevel>platform</privlevel>
/// <param name="installMode">Optional parameter to indicate special installation mode.</param>
/// <returns>Returns true if installation request is successful, false otherwise.</returns>
/// <remarks>
- /// The 'true' means that the request for installation is successful.
- /// To check the result of installation, the caller should check the progress using the InstallProgressChanged event or eventCallback.
+ /// True indicates that the installation request was successful. However, to determine whether the actual installation was completed successfully, the caller must monitor the progress by subscribing to the InstallProgressChanged event.
/// </remarks>
/// <privilege>http://tizen.org/privilege/packagemanager.admin</privilege>
/// <privlevel>platform</privlevel>
/// <param name="installMode">Optional parameter to indicate special installation mode.</param>
/// <returns>Returns true if installation request is successful, false otherwise.</returns>
/// <remarks>
- /// The 'true' means that the request for installation is successful.
- /// To check the result of installation, the caller should check the progress using the InstallProgressChanged event or eventCallback.
+ /// True indicates that the installation request was successful. However, to determine whether the actual installation was completed successfully, the caller must monitor the progress by subscribing to the InstallProgressChanged event.
/// </remarks>
/// <privilege>http://tizen.org/privilege/packagemanager.admin</privilege>
/// <privlevel>platform</privlevel>
/// <param name="installMode">Optional parameter to indicate special installation mode.</param>
/// <returns>Returns true if installation request is successful, false otherwise.</returns>
/// <remarks>
- /// The 'true' means that the request for installation is successful.
- /// To check the result of installation, the caller should check the progress using the InstallProgressChanged event or eventCallback.
+ /// True indicates that the installation request was successful. However, to determine whether the actual installation was completed successfully, the caller must monitor the progress by subscribing to the InstallProgressChanged event.
/// </remarks>
/// <privilege>http://tizen.org/privilege/packagemanager.admin</privilege>
/// <privlevel>platform</privlevel>
/// <param name="packageId">ID of the package to be uninstalled.</param>
/// <returns>Returns true if the uninstallation request is successful, false otherwise.</returns>
/// <remarks>
- /// The 'true' means that the request for uninstallation is successful.
- /// To check the result of uninstallation, the caller should check the progress using the UninstallProgressChanged event.
+ /// The return value 'true' indicates that the uninstallation request was successfully made. However, in order to determine whether the actual uninstallation process completed without any errors, the caller needs to monitor the progress through the UninstallProgressChanged event.
/// </remarks>
/// <privilege>http://tizen.org/privilege/packagemanager.admin</privilege>
/// <privlevel>platform</privlevel>
/// <param name="type">Optional - Package type for the package to be uninstalled.</param>
/// <returns>Returns true if the uninstallation request is successful, false otherwise.</returns>
/// <remarks>
- /// The 'true' means that the request for uninstallation is successful.
- /// To check the result of uninstallation, the caller should check the progress using the UninstallProgressChanged event.
+ /// The return value 'true' indicates that the uninstallation request was successfully made. However, in order to determine whether the actual uninstallation process completed without any errors, the caller needs to monitor the progress through the UninstallProgressChanged event.
/// </remarks>
/// <privilege>http://tizen.org/privilege/packagemanager.admin</privilege>
/// <privlevel>platform</privlevel>
/// <param name="eventCallback">Optional - The event callback will be invoked only for the current request.</param>
/// <returns>Returns true if the uninstallation request is successful, false otherwise.</returns>
/// <remarks>
- /// The 'true' means that the request for uninstallation is successful.
- /// To check the result of uninstallation, the caller should check the progress using the UninstallProgressChanged event or eventCallback.
+ /// The return value 'true' indicates that the uninstallation request was successfully made. However, in order to determine whether the actual uninstallation process completed without any errors, the caller needs to monitor the progress through the UninstallProgressChanged event.
/// </remarks>
/// <privilege>http://tizen.org/privilege/packagemanager.admin</privilege>
/// <privlevel>platform</privlevel>
/// <param name="eventCallback">Optional - The event callback will be invoked only for the current request.</param>
/// <returns>Returns true if the uninstallation request is successful, false otherwise.</returns>
/// <remarks>
- /// The 'true' means that the request for uninstallation is successful.
- /// To check the result of uninstallation, the caller should check the progress using the UninstallProgressChanged event or eventCallback.
+ /// The return value 'true' indicates that the uninstallation request was successfully made. However, in order to determine whether the actual uninstallation process completed without any errors, the caller needs to monitor the progress through the UninstallProgressChanged event.
/// </remarks>
/// <privilege>http://tizen.org/privilege/packagemanager.admin</privilege>
/// <privlevel>platform</privlevel>
/// <param name="newStorage">Storage package should be moved to.</param>
/// <returns>Returns true if the move request is successful, false otherwise.</returns>
/// <remarks>
- /// The 'true' means that the request for move is successful.
- /// To check the result of move, the caller should check the progress using the MoveProgressChanged event.
+ /// The return value 'true' indicates that the move request was successfully made.
+ /// To determine whether the actual move operation completed successfully, the caller needs to monitor the progress by handling the MoveProgressChanged event.
/// </remarks>
/// <privilege>http://tizen.org/privilege/packagemanager.admin</privilege>
/// <privlevel>platform</privlevel>
/// <param name="newStorage">Storage package should be moved to.</param>
/// <returns>Returns true if the move request is successful, false otherwise.</returns>
/// <remarks>
- /// The 'true' means that the request for move is successful.
- /// To check the result of move, the caller should check the progress using the MoveProgressChanged event.
+ /// The return value 'true' indicates that the move request was successfully made.
+ /// To determine whether the actual move operation completed successfully, the caller needs to monitor the progress by handling the MoveProgressChanged event.
/// </remarks>
/// <privilege>http://tizen.org/privilege/packagemanager.admin</privilege>
/// <privlevel>platform</privlevel>
/// <param name="eventCallback">Optional - The event callback will be invoked only for the current request.</param>
/// <returns>Returns true if move request is successful, false otherwise.</returns>
/// <remarks>
- /// The 'true' means that the request for move is successful.
- /// To check the result of move, the caller should check the progress using the MoveProgressChanged event.
+ /// The return value 'true' indicates that the move request was successfully made.
+ /// To determine whether the actual move operation completed successfully, the caller needs to monitor the progress by handling the MoveProgressChanged event.
/// </remarks>
/// <privilege>http://tizen.org/privilege/packagemanager.admin</privilege>
/// <privlevel>platform</privlevel>
/// <param name="eventCallback">Optional - The event callback will be invoked only for the current request.</param>
/// <returns>Returns true if move request is successful, false otherwise.</returns>
/// <remarks>
- /// The 'true' means that the request for move is successful.
- /// To check the result of move, the caller should check the progress using the MoveProgressChanged event.
+ /// The return value 'true' indicates that the move request was successfully made.
+ /// To determine whether the actual move operation completed successfully, the caller needs to monitor the progress by handling the MoveProgressChanged event.
/// </remarks>
/// <privilege>http://tizen.org/privilege/packagemanager.admin</privilege>
/// <privlevel>platform</privlevel>