IBinder.UnlinkToDeath(IBinderDeathRecipient, Int32) Method

Definition

Remove a previously registered death notification.

[Android.Runtime.Register("unlinkToDeath", "(Landroid/os/IBinder$DeathRecipient;I)Z", "GetUnlinkToDeath_Landroid_os_IBinder_DeathRecipient_IHandler:Android.OS.IBinderInvoker, Mono.Android, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null")]
public bool UnlinkToDeath (Android.OS.IBinderDeathRecipient recipient, int flags);
[<Android.Runtime.Register("unlinkToDeath", "(Landroid/os/IBinder$DeathRecipient;I)Z", "GetUnlinkToDeath_Landroid_os_IBinder_DeathRecipient_IHandler:Android.OS.IBinderInvoker, Mono.Android, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null")>]
abstract member UnlinkToDeath : Android.OS.IBinderDeathRecipient * int -> bool

Parameters

flags
Int32

Returns

true if the <var>recipient</var> is successfully unlinked, assuring you that its DeathRecipient#binderDied DeathRecipient.binderDied() method will not be called; false if the target IBinder has already died, meaning the method has been (or soon will be) called.

Attributes

Exceptions

if the given recipient has not been registered with the IBinder, and the IBinder is still alive. Note that if the recipient was never registered, but the IBinder has already died, then this exception will not be thrown, and you will receive a false return value instead.

Remarks

Java documentation for android.os.IBinder.unlinkToDeath(android.os.DeathRecipient, int).

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