Save the date! Android Dev Summit is coming to Sunnyvale, CA on Oct 23-24, 2019.

SocketKeepalive.Callback

public static class SocketKeepalive.Callback
extends Object

java.lang.Object
   ↳ android.net.SocketKeepalive.Callback


The callback which app can use to learn the status changes of SocketKeepalive. See SocketKeepalive.

Summary

Public constructors

SocketKeepalive.Callback()

Public methods

void onDataReceived()

The keepalive on a TCP socket was stopped because the socket received data.

void onError(int error)

An error occurred.

void onStarted()

The requested keepalive was successfully started.

void onStopped()

The keepalive was successfully stopped.

Inherited methods

Public constructors

SocketKeepalive.Callback

public SocketKeepalive.Callback ()

Public methods

onDataReceived

public void onDataReceived ()

The keepalive on a TCP socket was stopped because the socket received data.

onStarted

public void onStarted ()

The requested keepalive was successfully started.

onStopped

public void onStopped ()

The keepalive was successfully stopped.