/// <summary>
/// Initializes the instance of the AppControl class.
/// </summary>
- /// <exception cref="InvalidOperationException">Thrown when failed to create AppControl handle.</exception>
+ /// <exception cref="InvalidOperationException">Thrown when failed to create the AppControl handle.</exception>
public AppControl()
{
Interop.AppControl.ErrorCode err = Interop.AppControl.Create(out _handle);
}
/// <summary>
- /// Initializes the instance of the AppControl class with parameter.
+ /// Initializes the instance of the AppControl class with a parameter.
/// </summary>
- /// <param name="enableAppStartedResultEvent">The flag value to receive an additional launch result event on launch request.</param>
- /// <exception cref="InvalidOperationException">Thrown when failed to create AppControl handle.</exception>
+ /// <param name="enableAppStartedResultEvent">The flag value to receive an additional launch result event on the launch request.</param>
+ /// <exception cref="InvalidOperationException">Thrown when failed to create the AppControl handle.</exception>
public AppControl(bool enableAppStartedResultEvent)
{
Interop.AppControl.ErrorCode err = Interop.AppControl.Create(out _handle);
/// </summary>
/// <value>
/// Since Tizen 2.4, if the parameter 'uri' is started with 'file://' and
- /// it is a regular file in this application's data path which can be obtained
+ /// it is a regular file in this application's data path, which can be obtained
/// by property DataPath in ApplicationInfo class,
/// it will be shared to the callee application.
/// Framework will grant a temporary permission to the callee application for this file and
}
/// <summary>
- /// Gets and sets the application id to explicitly launch.
+ /// Gets and sets the application ID to explicitly launch.
/// </summary>
/// <value>
- /// (if the application id is null for setter, it clears the previous value.)
+ /// (if the application ID is null for setter, it clears the previous value.)
/// </value>
/// <example>
/// <code>
/// Gets and sets the launch mode of the application.
/// </summary>
/// <value>
- /// Although LaunchMode were set as AppControlLaunchMode.Group,
- /// callee application would be launched as single mode
+ /// Although, LaunchMode were set as AppControlLaunchMode.Group, the
+ /// callee application would be launched as a single mode
/// if the manifest file of callee application defined the launch mode as "single".
- /// This property can just set the preference of caller application to launch an application.
- /// Sub-applications which were launched as group mode always have own process.
- /// Since Tizen 3.0, if launch mode not set in the caller app control,
- /// this property returns AppControlLaunchMode.Single launch mode.
+ /// This property can just set the preference of the caller application to launch an application.
+ /// Sub-applications, which were launched as a group mode always have own process.
+ /// Since Tizen 3.0, if launch mode is not set in the caller application control,
+ /// this property returns the AppControlLaunchMode.Single launch mode.
/// </value>
/// <example>
/// <code>
/// <summary>
/// Retrieves all applications that can be launched to handle the given app_control request.
/// </summary>
- /// <param name="control">The AppControl</param>
- /// <returns>ApplicationIds</returns>
- /// <exception cref="InvalidOperationException">Thrown when failed because of invalid parameter</exception>
+ /// <param name="control">The AppControl.</param>
+ /// <returns>ApplicationIds.</returns>
+ /// <exception cref="InvalidOperationException">Thrown when failed because of an invalid parameter.</exception>
/// <example>
/// <code>
- /// IEnumerable<string> applicationIds = AppControl.GetMatchedApplicationIds(control);
+ /// IEnumerable<string> applicationIds = AppControl.GetMatchedApplicationIds(control);
/// if (applicationIds != null)
/// {
/// foreach (string id in applicationIds)
/// If the operation is AppControlOperations.Default, the application ID is mandatory to explicitly launch the application. \n
/// Since Tizen 2.4, the launch request of the service application over out of packages is restricted by the platform.
/// Also, implicit launch requests are NOT delivered to service applications since 2.4.
- /// To launch a service application, an explicit launch request with application ID given by property ApplicationId MUST be sent.
+ /// To launch a service application, an explicit launch request with the application ID given by property ApplicationId MUST be sent.
/// </remarks>
- /// <param name="launchRequest">The AppControl</param>
- /// <exception cref="ArgumentNullException">Thrown when failed because of a null arguament</exception>
- /// <exception cref="InvalidOperationException">Thrown when failed because of invalid operation</exception>
- /// <exception cref="TimeoutException">Thrown when failed because of timeout</exception>
+ /// <param name="launchRequest">The AppControl.</param>
+ /// <exception cref="ArgumentNullException">Thrown when failed because of a null argument.</exception>
+ /// <exception cref="InvalidOperationException">Thrown when failed because of an invalid operation.</exception>
+ /// <exception cref="TimeoutException">Thrown when failed because of timeout.</exception>
/// <privilege>http://tizen.org/privilege/appmanager.launch</privilege>
/// <example>
/// <code>
/// If the operation is AppControlOperations.Default, the application ID is mandatory to explicitly launch the application. \n
/// Since Tizen 2.4, the launch request of the service application over out of packages is restricted by the platform.
/// Also, implicit launch requests are NOT delivered to service applications since 2.4.
- /// To launch a service application, an explicit launch request with application ID given by property ApplicationId MUST be sent.
+ /// To launch a service application, an explicit launch request with the application ID given by property ApplicationId MUST be sent.
/// </remarks>
- /// <param name="launchRequest">The AppControl</param>
- /// <param name="replyAfterLaunching">The callback function to be called when the reply is delivered</param>
- /// <exception cref="ArgumentException">Thrown when failed because of arguament is invalid</exception>
- /// <exception cref="InvalidOperationException">Thrown when failed because of invalid operation</exception>
- /// <exception cref="TimeoutException">Thrown when failed because of timeout</exception>
+ /// <param name="launchRequest">The AppControl.</param>
+ /// <param name="replyAfterLaunching">The callback function to be called when the reply is delivered.</param>
+ /// <exception cref="ArgumentException">Thrown when failed because of the argument is invalid.</exception>
+ /// <exception cref="Exceptions.AppNotFoundException">Thrown when the application to run is not found.</exception>
+ /// <exception cref="Exceptions.LaunchFailedException">Thrown when the request failed to launch the application.</exception>
+ /// <exception cref="Exceptions.LaunchRejectedException">Thrown when the launch request is rejected.</exception>
+ /// <exception cref="Exceptions.OutOfMemoryException">Thrown when the memory is insufficient.</exception>
+ /// <exception cref="Exceptions.PermissionDeniedException">Thrown when the permission is denied.</exception>
+ /// <exception cref="TimeoutException">Thrown when failed because of timeout.</exception>
/// <privilege>http://tizen.org/privilege/appmanager.launch</privilege>
/// <example>
/// <code>
throw new ArgumentException("Invalid Arguments");
case Interop.AppControl.ErrorCode.TimedOut:
throw new TimeoutException("Timed out");
+ case Interop.AppControl.ErrorCode.OutOfMemory:
+ throw new Exceptions.OutOfMemoryException("Out-of-memory");
+ case Interop.AppControl.ErrorCode.AppNotFound:
+ throw new Exceptions.AppNotFoundException("App not found");
+ case Interop.AppControl.ErrorCode.LaunchRejected:
+ throw new Exceptions.LaunchRejectedException("Launch rejected");
+ case Interop.AppControl.ErrorCode.LaunchFailed:
+ throw new Exceptions.LaunchFailedException("Launch failed");
+ case Interop.AppControl.ErrorCode.PermissionDenied:
+ throw new Exceptions.PermissionDeniedException("Permission denied");
+
default:
- throw new InvalidOperationException("Error = " + err);
+ throw new Exceptions.LaunchRejectedException("Launch rejected");
}
}
}
/// </summary>
/// <remarks>
/// You are not allowed to terminate other general applications using this API.
- /// This API can be used to terminate sub-applications which were launched as group mode by caller application.
- /// Once callee application is being terminated by this API,
- /// other applications which were launched by callee application as group mode will be terminated as well
+ /// This API can be used to terminate sub-applications, which were launched as a group mode by the caller application.
+ /// Once the callee application is being terminated by this API,
+ /// other applications, which were launched by the callee application as a group mode will be terminated as well.
/// </remarks>
- /// <param name="terminateRequest">The AppControl</param>
- /// <exception cref="ArgumentException">Thrown when failed because of arguament is invalid</exception>
- /// <exception cref="InvalidOperationException">Thrown when failed because of invalid operation</exception>
- /// <exception cref="TimeoutException">Thrown when failed because of timeout</exception>
+ /// <param name="terminateRequest">The AppControl.</param>
+ /// <exception cref="ArgumentException">Thrown when failed because of the argument is invalid.</exception>
+ /// <exception cref="InvalidOperationException">Thrown when failed because of an invalid operation.</exception>
+ /// <exception cref="TimeoutException">Thrown when failed because of timeout.</exception>
/// <example>
/// <code>
/// AppControl terminateRequest = new AppControl();
}
/// <summary>
- /// Class for Extra Data
+ /// Class for extra data.
/// </summary>
public class ExtraDataCollection
{
/// <remarks>
/// The function replaces any existing value for the given key.
/// </remarks>
- /// <param name="key">The name of the extra data</param>
- /// <param name="value">The value associated with the given key</param>
- /// <exception cref="ArgumentNullException">Thrown when key or value is a zero-length string</exception>
- /// <exception cref="ArgumentException">Thrown when the application tries to use the same key with system-defined key</exception>
+ /// <param name="key">The name of the extra data.</param>
+ /// <param name="value">The value associated with the given key.</param>
+ /// <exception cref="ArgumentNullException">Thrown when a key or a value is a zero-length string.</exception>
+ /// <exception cref="ArgumentException">Thrown when the application tries to use the same key with the system-defined key.</exception>
/// <example>
/// <code>
/// AppControl appControl = new AppControl();
/// <remarks>
/// The function replaces any existing value for the given key.
/// </remarks>
- /// <param name="key">The name of the extra data</param>
- /// <param name="value">The value associated with the given key</param>
- /// <exception cref="ArgumentNullException">Thrown when key or value is a zero-length string</exception>
- /// <exception cref="ArgumentException">Thrown when the application tries to use the same key with system-defined key</exception>
+ /// <param name="key">The name of the extra data.</param>
+ /// <param name="value">The value associated with the given key.</param>
+ /// <exception cref="ArgumentNullException">Thrown when key or value is a zero-length string.</exception>
+ /// <exception cref="ArgumentException">Thrown when the application tries to use the same key with the system-defined key.</exception>
/// <example>
/// <code>
/// AppControl appControl = new AppControl();
/// Gets the extra data.
/// </summary>
/// <typeparam name="T">Only string and IEnumerable<string></typeparam>
- /// <param name="key">The name of extra data</param>
- /// <returns>The value associated with the given key</returns>
- /// <exception cref="ArgumentNullException">Thrown when the key is invalid parameter</exception>
- /// <exception cref="KeyNotFoundException">Thrown when the key is not found</exception>
- /// <exception cref="ArgumentException">Thrown when the key is rejected</exception>
+ /// <param name="key">The name of extra data.</param>
+ /// <returns>The value associated with the given key.</returns>
+ /// <exception cref="ArgumentNullException">Thrown when the key is an invalid parameter.</exception>
+ /// <exception cref="KeyNotFoundException">Thrown when the key is not found.</exception>
+ /// <exception cref="ArgumentException">Thrown when the key is rejected.</exception>
/// <example>
/// <code>
/// AppControl appControl = new AppControl();
- /// string myValue = appControl.ExtraData.Get<string>("myKey");
+ /// string myValue = appControl.ExtraData.Get<string>("myKey");
/// </code>
/// </example>
public T Get<T>(string key)
/// <summary>
/// Gets the extra data.
/// </summary>
- /// <param name="key">The name of extra data</param>
- /// <returns>The value associated with the given key</returns>
- /// <exception cref="ArgumentNullException">Thrown when the key is invalid parameter</exception>
- /// <exception cref="KeyNotFoundException">Thrown when the key is not found</exception>
- /// <exception cref="ArgumentException">Thrown when the key is rejected</exception>
+ /// <param name="key">The name of extra data.</param>
+ /// <returns>The value associated with the given key.</returns>
+ /// <exception cref="ArgumentNullException">Thrown when the key is an invalid parameter.</exception>
+ /// <exception cref="KeyNotFoundException">Thrown when the key is not found.</exception>
+ /// <exception cref="ArgumentException">Thrown when the key is rejected.</exception>
/// <example>
/// <code>
/// AppControl appControl = new AppControl();
/// <summary>
/// Gets all keys in extra data.
/// </summary>
- /// <returns>The keys in the AppControl</returns>
- /// <exception cref="InvalidOperationException">Thrown when invalid parameter</exception>
+ /// <returns>The keys in the AppControl.</returns>
+ /// <exception cref="InvalidOperationException">Thrown when the key is an invalid parameter.</exception>
/// <example>
/// <code>
/// AppControl appControl = new AppControl();
- /// IEnumerable<string> keys = appControl.GetKeys();
+ /// IEnumerable<string> keys = appControl.GetKeys();
/// if (keys != null)
/// {
/// foreach (string key in keys)
/// <summary>
/// Tries getting the extra data.
/// </summary>
- /// <param name="key">The name of extra data</param>
- /// <param name="value">The value associated with the given key</param>
- /// <returns>The result whether getting the value is done</returns>
- /// <exception cref="ArgumentNullException">Thrown when the key is invalid parameter</exception>
- /// <exception cref="KeyNotFoundException">Thrown when the key is not found</exception>
- /// <exception cref="ArgumentException">Thrown when the key is rejected</exception>
+ /// <param name="key">The name of extra data.</param>
+ /// <param name="value">The value associated with the given key.</param>
+ /// <returns>The result whether getting the value is done.</returns>
+ /// <exception cref="ArgumentNullException">Thrown when the key is an invalid parameter.</exception>
+ /// <exception cref="KeyNotFoundException">Thrown when the key is not found.</exception>
+ /// <exception cref="ArgumentException">Thrown when the key is rejected.</exception>
/// <example>
/// <code>
/// AppControl appControl = new AppControl();
/// <summary>
/// Tries getting the extra data.
/// </summary>
- /// <param name="key">The name of extra data</param>
- /// <param name="value">The value associated with the given key</param>
- /// <returns>The result whether getting the value is done</returns>
- /// <exception cref="ArgumentNullException">Thrown when the key is invalid parameter</exception>
- /// <exception cref="KeyNotFoundException">Thrown when the key is not found</exception>
- /// <exception cref="ArgumentException">Thrown when the key is rejected</exception>
+ /// <param name="key">The name of extra data.</param>
+ /// <param name="value">The value associated with the given key.</param>
+ /// <returns>The result whether getting the value is done.</returns>
+ /// <exception cref="ArgumentNullException">Thrown when the key is an invalid parameter.</exception>
+ /// <exception cref="KeyNotFoundException">Thrown when the key is not found.</exception>
+ /// <exception cref="ArgumentException">Thrown when the key is rejected.</exception>
/// <example>
/// <code>
/// AppControl appControl = new AppControl();
- /// IEnumerable<string> myValue = null;
+ /// IEnumerable<string> myValue = null;
/// bool result = appControl.ExtraData.TryGet("myKey", out myValue);
/// if (result)
/// {
/// <summary>
/// Removes the extra data.
/// </summary>
- /// <param name="key">The name of the extra data</param>
- /// <exception cref="ArgumentNullException">Thrown when the key is a zero-length string</exception>
- /// <exception cref="KeyNotFoundException">Thrown when the key is not found</exception>
- /// <exception cref="ArgumentException">Thrown when the key is rejected</exception>
+ /// <param name="key">The name of the extra data.</param>
+ /// <exception cref="ArgumentNullException">Thrown when the key is a zero-length string.</exception>
+ /// <exception cref="KeyNotFoundException">Thrown when the key is not found.</exception>
+ /// <exception cref="ArgumentException">Thrown when the key is rejected.</exception>
/// <example>
/// <code>
/// AppControl appControl = new AppControl();
/// <summary>
/// Counts keys in the extra data.
/// </summary>
- /// <returns>The number of counting keys</returns>
- /// <exception cref="InvalidOperationException">Thrown when invalid parameter</exception>
+ /// <returns>The number of counting keys.</returns>
+ /// <exception cref="InvalidOperationException">Thrown when the key is an invalid parameter.</exception>
/// <example>
/// <code>
/// AppControl appControl = new AppControl();
}
/// <summary>
- /// Checks whether the extra data associated with the given key is of collection data type.
+ /// Checks whether the extra data associated with the given key is of the collection data type.
/// </summary>
- /// <param name="key">The name of the extra data</param>
- /// <returns>If true the extra data is of array data type, otherwise false</returns>
- /// <exception cref="ArgumentNullException">Thrown when the key is a zero-length string</exception>
- /// <exception cref="InvalidOperationException">Thrown when failed to check the key</exception>
+ /// <param name="key">The name of the extra data.</param>
+ /// <returns>If true, the extra data is of the array data type, otherwise false.</returns>
+ /// <exception cref="ArgumentNullException">Thrown when the key is a zero-length string.</exception>
+ /// <exception cref="InvalidOperationException">Thrown when failed to check the key.</exception>
/// <example>
/// <code>
/// AppControl appControl = new AppControl();