AnyLogic
Expand
Font size
    java.lang.Object
      com.anylogic.engine.presentation.NetworkActivityMonitorService

@AnyLogicInternalAPI
public class NetworkActivityMonitorService
extends Object
This class is internal and shouldn't be called by user.
it may be removed/renamed in future.

Constructor Summary

ConstructorDescription
NetworkActivityMonitorService() 

Method Summary

Modifier and TypeMethodDescription
static NetworkConnectionHandlercreateNetworkConnectionStatusMonitor()
This method is internal and shouldn't be called by user.
it may be removed/renamed in future.
It is designed for various places where connections are created.
Usage:
static intgetActiveConnectionsCount()
This method is internal and shouldn't be called by user.
it may be removed/renamed in future.

Methods inherited from class java.lang.Object

equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Constructor Details

NetworkActivityMonitorService

public NetworkActivityMonitorService()

Method Details

createNetworkConnectionStatusMonitor

@AnyLogicInternalAPI
public static NetworkConnectionHandler createNetworkConnectionStatusMonitor()
This method is internal and shouldn't be called by user.
it may be removed/renamed in future.
It is designed for various places where connections are created.
Usage:
 try ( NetworkConnectionHandler m = NetworkActivityMonitorService.createNetworkConnectionStatusMonitor() ) {
        // your code accessing network
 }
See Also:

getActiveConnectionsCount

@AnyLogicInternalAPI
public static int getActiveConnectionsCount()
This method is internal and shouldn't be called by user.
it may be removed/renamed in future.
Returns:
the number of active connections