Stay organized with collections
Save and categorize content based on your preferences.
IInterface
public
interface
IInterface
Base class for Binder interfaces. When defining a new interface,
you must derive it from IInterface.
Summary
Public methods |
abstract
IBinder
|
asBinder()
Retrieve the Binder object associated with this interface.
|
Public methods
asBinder
public abstract IBinder asBinder ()
Retrieve the Binder object associated with this interface.
You must use this instead of a plain cast, so that proxy objects
can return the correct result.
Content and code samples on this page are subject to the licenses described in the Content License. Java and OpenJDK are trademarks or registered trademarks of Oracle and/or its affiliates.
Last updated 2025-02-10 UTC.
[null,null,["Last updated 2025-02-10 UTC."],[],[],null,["# IInterface\n\nAdded in [API level 1](/guide/topics/manifest/uses-sdk-element#ApiLevels) \n\nIInterface\n==========\n\n*** ** * ** ***\n\n[Kotlin](/reference/kotlin/android/os/IInterface \"View this page in Kotlin\") \\|Java\n\n\n`\npublic\n\n\ninterface\nIInterface\n`\n\n\n`\n\n\n`\n\n|-----------------------|\n| android.os.IInterface |\n\n\u003cbr /\u003e\n\n*** ** * ** ***\n\nBase class for Binder interfaces. When defining a new interface,\nyou must derive it from IInterface.\n\nSummary\n-------\n\n| ### Public methods ||\n|------------------------------------------------------|----------------------------------------------------------------------------------------------------------------------------|\n| ` abstract `[IBinder](/reference/android/os/IBinder) | ` `[asBinder](/reference/android/os/IInterface#asBinder())`() ` Retrieve the Binder object associated with this interface. |\n\nPublic methods\n--------------\n\n### asBinder\n\nAdded in [API level 1](/guide/topics/manifest/uses-sdk-element#ApiLevels) \n\n```\npublic abstract IBinder asBinder ()\n```\n\nRetrieve the Binder object associated with this interface.\nYou must use this instead of a plain cast, so that proxy objects\ncan return the correct result.\n\n\u003cbr /\u003e\n\n| Returns ||\n|------------------------------------------|--------|\n| [IBinder](/reference/android/os/IBinder) | \u003cbr /\u003e |"]]