Connections.EndpointDiscoveryListener | Android Developers

Quicknav Quicknav
Links

- Google Play Developer Console
- Android Developers Blog
- About Android

Android Sites

- Android.com
- Android Developers
- Android Open Source Project

Language
close

- - About
  - Wear
  - TV
  - Auto
- - Get Started
  - Devices
  - Style
  - Patterns
  - Building Blocks
  - Downloads
  - Videos
- - Training
  - API Guides
  - Reference
  - Tools
  - Google Services
  - Samples
- - Google Play
  - Essentials
  - Get Users
  - Engage & Retain
  - Monetize
  - Analyze
  - Tools & Reference
  - Developer Stories

## Results

Loading...
public static interface

# Connections.EndpointDiscoveryListener

com.google.android.gms.nearby.connection.Connections.EndpointDiscoveryListener

## Class Overview

Listener invoked during endpoint discovery.

## Summary

Public Methods
abstract void | onEndpointFound(String endpointId, String deviceId, String serviceId, String name) Called when a remote endpoint is discovered.
abstract void | onEndpointLost(String endpointId) Called when a remote endpoint is no longer discoverable; only called for endpoints that previously had been passed to `onEndpointFound(String, String, String, String)`.

## Public Methods

#### public abstract void onEndpointFound (String endpointId, String deviceId, String serviceId, String name)

Called when a remote endpoint is discovered.

##### Parameters

endpointId | The ID of the remote endpoint that was discovered.
deviceId | The ID of the remote device that was discovered.
serviceId | The ID of the service of the remote endpoint.
name | The human readable name of the remote endpoint.

#### public abstract void onEndpointLost (String endpointId)

Called when a remote endpoint is no longer discoverable; only called for endpoints that previously had been passed to `onEndpointFound(String, String, String, String)`.

##### Parameters

endpointId | The ID of the remote endpoint that was lost.