| com.google.android.gms.nearby.connection.Connections.MessageListener |
Listener for messages from a remote endpoint.
| Public Methods | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
Called when a remote endpoint is disconnected / becomes unreachable.
| |||||||||||
Called when a message is received from a remote endpoint.
| |||||||||||
Called when a remote endpoint is disconnected / becomes unreachable.
| remoteEndpointId | The identifier for the remote endpoint that disconnected. |
|---|
Called when a message is received from a remote endpoint.
| remoteEndpointId | The identifier for the remote endpoint that sent the message. |
|---|---|
| payload | The bytes of the message sent by the remote endpoint. This array will not
exceed MAX_RELIABLE_MESSAGE_LEN bytes for reliable messages, or
MAX_UNRELIABLE_MESSAGE_LEN for unreliable ones. |
| isReliable | True if the message was sent reliably, false otherwise. |