Expand Minimize Picture-in-picture Power Device Status Voice Recognition Skip Back Skip Forward Minus Plus Play Search
Internet Explorer alert
This browser is not recommended for use with smartdevicelink.com, and may not function properly. Upgrade to a different browser to guarantee support of all features.
close alert
To Top Created with Sketch. To Top
To Bottom Created with Sketch. To Bottom
Android Documentation
IHeartbeatMonitor

Interface IHeartbeatMonitor

Package
com.smartdevicelink.protocol.heartbeat
All Known Implementing Classes
com.smartdevicelink.protocol.heartbeat.HeartbeatMonitor

Methods

start()

Starts the monitor. If the monitor is already started, nothing happens.

public void start()

stop()

Stops the monitor. Does nothing if it is already stopped.

public void stop()

getInterval()

Returns the heartbeat messages interval.

public int getInterval()

setInterval( int interval )

Sets the interval for sending heartbeat messages if nothing is sent over transport.

public void setInterval(int interval)

Method Parameters

interval
interval in milliseconds (min/max values depend on concrete implementations)

getListener()

Returns the listener.

public com.smartdevicelink.protocol.heartbeat.IHeartbeatMonitorListener getListener()

setListener( IHeartbeatMonitorListener listener )

Sets the heartbeat's listener.

public void setListener(IHeartbeatMonitorListener listener)

Method Parameters

listener
the new listener

notifyTransportActivity()

Notifies the monitor about sent/received messages.

public void notifyTransportActivity()

heartbeatACKReceived()

Notifies the monitor about a received heartbeat ACK message.

public void heartbeatACKReceived()

heartbeatReceived()

Notifies the monitor about a received heartbeat message.

public void heartbeatReceived()
View on GitHub.com
Previous Section Next Section