Service.OnTaskRemoved(Intent) Method
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
This is called if the service is currently running and the user has removed a task that comes from the service's application.
[Android.Runtime.Register("onTaskRemoved", "(Landroid/content/Intent;)V", "GetOnTaskRemoved_Landroid_content_Intent_Handler")]
public virtual void OnTaskRemoved (Android.Content.Intent? rootIntent);
[<Android.Runtime.Register("onTaskRemoved", "(Landroid/content/Intent;)V", "GetOnTaskRemoved_Landroid_content_Intent_Handler")>]
abstract member OnTaskRemoved : Android.Content.Intent -> unit
override this.OnTaskRemoved : Android.Content.Intent -> unit
- rootIntent
- Intent
The original root Intent that was used to launch the task that is being removed.
- Attributes
This is called if the service is currently running and the user has removed a task that comes from the service's application. If you have set android.content.pm.ServiceInfo#FLAG_STOP_WITH_TASK ServiceInfo.FLAG_STOP_WITH_TASK
then you will not receive this callback; instead, the service will simply be stopped.
Java documentation for android.app.Service.onTaskRemoved(android.content.Intent)
.
Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.
Product | Versions |
---|---|
.NET for Android | .NET for Android API 34, .NET for Android API 35 |