Udostępnij za pośrednictwem


IServiceConnection.OnBindingDied(ComponentName) Method

Definition

Called when the binding to this connection is dead.

[Android.Runtime.Register("onBindingDied", "(Landroid/content/ComponentName;)V", "GetOnBindingDied_Landroid_content_ComponentName_Handler:Android.Content.IServiceConnection, Mono.Android, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null", ApiSince=26)]
public virtual void OnBindingDied (Android.Content.ComponentName? name);
[<Android.Runtime.Register("onBindingDied", "(Landroid/content/ComponentName;)V", "GetOnBindingDied_Landroid_content_ComponentName_Handler:Android.Content.IServiceConnection, Mono.Android, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null", ApiSince=26)>]
abstract member OnBindingDied : Android.Content.ComponentName -> unit
override this.OnBindingDied : Android.Content.ComponentName -> unit

Parameters

name
ComponentName

The concrete component name of the service whose connection is dead.

Attributes

Remarks

Called when the binding to this connection is dead. This means the interface will never receive another connection. The application will need to unbind and rebind the connection to activate it again. This may happen, for example, if the application hosting the service it is bound to has been updated.

<p class="note"><b>Note:</b> The app that requested the binding must call Context#unbindService(ServiceConnection) to release the tracking resources associated with this ServiceConnection even if this callback was invoked following Context#bindService Context.bindService() bindService().

Java documentation for android.content.ServiceConnection.onBindingDied(android.content.ComponentName).

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.

Applies to