CompanionDeviceManager.Callback

public static abstract class CompanionDeviceManager.Callback
extends Object

java.lang.Object
   ↳ android.companion.CompanionDeviceManager.Callback


A callback to receive once at least one suitable device is found, or the search failed (e.g. timed out)

Summary

Public constructors

CompanionDeviceManager.Callback()

Public methods

abstract void onDeviceFound(IntentSender chooserLauncher)

Called once at least one suitable device is found

abstract void onFailure(CharSequence error)

Called if there was an error looking for device(s)

Inherited methods

Public constructors

CompanionDeviceManager.Callback

added in API level 26
CompanionDeviceManager.Callback ()

Public methods

onDeviceFound

added in API level 26
void onDeviceFound (IntentSender chooserLauncher)

Called once at least one suitable device is found

Parameters
chooserLauncher IntentSender: a IntentSender to launch the UI for user to select a device

onFailure

added in API level 26
void onFailure (CharSequence error)

Called if there was an error looking for device(s)

Parameters
error CharSequence: the cause of the error