com.mobiledgex.matchingengine.EdgeEventsConnection Class Reference


enum  EdgeEventsError
enum  EdgeEventsStatus

Public Member Functions

boolean addEdgeEventsIntervalTask (EdgeEventsIntervalHandler edgeEventsIntervalHandler)
boolean removeEdgeEventsIntervalTask (EdgeEventsIntervalHandler edgeEventsIntervalHandler)
Location getLastLocationPosted ()
synchronized void setLastLocationPosted (Location mLastLocationPosted)
synchronized void reconnect (EdgeEventsConfig eeConfig) throws DmeDnsException
long getOpenTimeoutMs ()
void setOpenTimeout (long timeoutMs)
boolean isShutdown ()
synchronized boolean send (final AppClient.ClientEdgeEvent clientEdgeEvent)
Location getLocation ()
synchronized boolean postLocationUpdate (Location location)
synchronized boolean postLatencyUpdate (Site site, Location location)
synchronized boolean testPingAndPostLatencyUpdate (Location location)
synchronized boolean testConnectAndPostLatencyUpdate (Location location)
synchronized boolean testConnectAndPostLatencyUpdate (int internalPort, Location location)
synchronized boolean runEdgeEvents ()
void stopEdgeEvents ()

Public Attributes

final long OPEN_TIMEOUT_MS = 10 * 1000
boolean reconnectOnError = true

Static Public Attributes

static final String TAG = "EdgeEventsConnection"

Detailed Description

EdgeEventsConnection provides a asynchronous bi-directional connection to the server side DME.

Member Function Documentation

◆ addEdgeEventsIntervalTask()

boolean com.mobiledgex.matchingengine.EdgeEventsConnection.addEdgeEventsIntervalTask ( EdgeEventsIntervalHandler  edgeEventsIntervalHandler)

Submit a new scheduled task into a managed set of configured EdgeEvents onInterval Tasks. The task will then have its lifetime managed according to the lifecycle of the EdgeEventsConnection status.

the(scheduled) or started task to add.

◆ getLocation()

Location com.mobiledgex.matchingengine.EdgeEventsConnection.getLocation ( )

Get Location. This is a blocking call.

◆ getOpenTimeoutMs()

long com.mobiledgex.matchingengine.EdgeEventsConnection.getOpenTimeoutMs ( )

Gets the timeout for opening a connection.

◆ reconnect()

synchronized void com.mobiledgex.matchingengine.EdgeEventsConnection.reconnect ( EdgeEventsConfig  eeConfig) throws DmeDnsException

Reconnects the EdgeEventsConnection with current settings. This will block until opened.

◆ removeEdgeEventsIntervalTask()

boolean com.mobiledgex.matchingengine.EdgeEventsConnection.removeEdgeEventsIntervalTask ( EdgeEventsIntervalHandler  edgeEventsIntervalHandler)

Remove a Scheduled EdgeEvents Task. This will attempt to stop, then remove the task.

edgeEventsIntervalHandlerthe task to remove.

◆ setOpenTimeout()

void com.mobiledgex.matchingengine.EdgeEventsConnection.setOpenTimeout ( long  timeoutMs)

Sets the timeout to open a connection.

timeoutMstimeout in MS. If <= 0, uses default.