nn.pp.rccore

## Interface ConnectionEventListener

- All Known Implementing Classes:
    RCAdapter

      public interface ConnectionEventListener

  Event handlers for various KVM session and information events
  See Also:
    `RCCore.addConnectionEventListener(ConnectionEventListener, int)`, `RCCore.removeConnectionEventListener(ConnectionEventListener)`

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static int` | `ALL` All registration bits
    `static int` | `CHAT` Deprecated.
    `static int` | `CIM_LANG_OPTION` Registration bit for CIM language option related events
    `static int` | `CONNECTED_USERS` Registration bit for connected users related events
    `static int` | `DEVICE_NAME` Registration bit for device name related events
    `static int` | `ERIC_SESSION_ID_CHANGED` Registration bit for eric session ID related events
    `static int` | `ETH_GIGABIT_SUPPORT` Registration bit for Gigabit Ethernet related events
    `static int` | `EXCLUSIVE_MODE` Deprecated.
    `static int` | `FEATURE_SUPPORT` Registration bit for feature support related events
    `static int` | `HIDE_TOOLBAR` Registration bit for toolbar related events
    `static int` | `LANGUAGE` Deprecated.
    `static int` | `LICENSE_SUPPORT` Registration bit for licensing support related events
    `static int` | `MONITOR_MODE` Deprecated.
    `static int` | `PORT_LIST` Registration bit for port list related events
    `static int` | `POWER_CONTROL` Registration bit for power control related events
    `static int` | `PROTOCOL_VERSION` Registration bit for protocol version related events
    `static int` | `SERVER_ID` Registration bit for server ID related events
    `static int` | `STATUS_INFO` Registration bit for status info related events
    `static int` | `SWITCHED_TO_PORT` Registration bit for switched to port
    `static int` | `USB_PROFILE` Registration bit for USB profile related events

  - ### Method Summary

    All Methods Instance Methods Abstract Methods Deprecated Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `chatWelcomeChanged(java.lang.String welcome)` Deprecated.
    `void` | `cimLanguageOptionsSupported(boolean supported)` CIM options supported
    `void` | `connected()` The Connection has successfully been established and the initial handshake has been processed.
    `void` | `connectedUsersChanged(int users)` The number of connected users has changed
    `void` | `deviceNameChanged(java.lang.String deviceName)` The name of the device connected to has been received or changed
    `void` | `disconnected(java.lang.Exception e)` The Connection has been dropped.
    `void` | `ericSessionIdChanged(java.lang.String ericSessionId)` The eric session ID has been received or changed
    `void` | `ethernetGigabitSupported(boolean supported)` Gigabit ethernet support
    `void` | `exclusiveModeChanged(boolean exclusive)` Deprecated.
    `void` | `exclusiveModePermissionChanged(boolean allowed)` Deprecated.
    `void` | `framesPerSecond(int frames)` Frames per second decoded by the KVM protocol
    `void` | `hideClientMenuEnforcedChanged(boolean enforced)` The setting whether hiding the client's tool bar and menu bar is enforced by configuration has changed
    `void` | `incomingTrafficSpeed(int speed)` Incoming traffic speed
    `void` | `languageChanged(java.util.Locale language)` Deprecated.
    `void` | `licenseFeatureSupportChanged(java.lang.String feature, boolean supported)` Licensed features have changed
    `void` | `monitorModeChanged(boolean monitor)` Deprecated.
    `void` | `monitorModePermissionChanged(boolean allowed)` Deprecated.
    `void` | `newChatMessage(java.lang.String message)` Deprecated.
    `void` | `outgoingTrafficSpeed(int speed)` Outgoing traffic speed
    `java.lang.String` | `portListChanged(java.util.List<? extends IKvmPort> portList)` The KVM Port List has changed; The event handler can select a port from the list and return it.
    `void` | `portListRefreshSupportChanged(boolean supported)` The support for requesting the port list refresh has changed.
    `void` | `portScanSupportChanged(boolean supported)` The support for the Port Scan feature has changed
    `void` | `powerControlEnabledChanged(boolean enabled)` Power control enabled has changed
    `void` | `protocolVersionChanged(java.lang.String protocolVersion)` The RFB protocol version has been received or changed
    `void` | `serverSessionIdChanged(int serverId)` The session ID has been received or changed
    `void` | `switchedToPort(java.lang.String portId)` Successfully switched to a target port.

- - ### Field Detail

    - #### PORT_LIST

          static final int PORT_LIST

      Registration bit for port list related events
      See Also:
        Constant Field Values

    - #### SERVER_ID

          static final int SERVER_ID

      Registration bit for server ID related events
      See Also:
        Constant Field Values

    - #### CONNECTED_USERS

          static final int CONNECTED_USERS

      Registration bit for connected users related events
      See Also:
        Constant Field Values

    - #### MONITOR_MODE

          @Deprecated
          static final int MONITOR_MODE

      Deprecated.
      Registration bit for monitor mode related events
      See Also:
        Constant Field Values

    - #### EXCLUSIVE_MODE

          @Deprecated
          static final int EXCLUSIVE_MODE

      Deprecated.
      Registration bit for exclusive mode related events
      See Also:
        Constant Field Values

    - #### LANGUAGE

          @Deprecated
          static final int LANGUAGE

      Deprecated.
      Registration bit for language related events
      See Also:
        Constant Field Values

    - #### PROTOCOL_VERSION

          static final int PROTOCOL_VERSION

      Registration bit for protocol version related events
      See Also:
        Constant Field Values

    - #### DEVICE_NAME

          static final int DEVICE_NAME

      Registration bit for device name related events
      See Also:
        Constant Field Values

    - #### STATUS_INFO

          static final int STATUS_INFO

      Registration bit for status info related events
      See Also:
        Constant Field Values

    - #### CHAT

          @Deprecated
          static final int CHAT

      Deprecated.
      Registration bit for chat related events
      See Also:
        Constant Field Values

    - #### USB_PROFILE

          static final int USB_PROFILE

      Registration bit for USB profile related events
      See Also:
        Constant Field Values

    - #### CIM_LANG_OPTION

          static final int CIM_LANG_OPTION

      Registration bit for CIM language option related events
      See Also:
        Constant Field Values

    - #### ETH_GIGABIT_SUPPORT

          static final int ETH_GIGABIT_SUPPORT

      Registration bit for Gigabit Ethernet related events
      See Also:
        Constant Field Values

    - #### ERIC_SESSION_ID_CHANGED

          static final int ERIC_SESSION_ID_CHANGED

      Registration bit for eric session ID related events
      See Also:
        Constant Field Values

    - #### LICENSE_SUPPORT

          static final int LICENSE_SUPPORT

      Registration bit for licensing support related events
      See Also:
        Constant Field Values

    - #### POWER_CONTROL

          static final int POWER_CONTROL

      Registration bit for power control related events
      See Also:
        Constant Field Values

    - #### HIDE_TOOLBAR

          static final int HIDE_TOOLBAR

      Registration bit for toolbar related events
      See Also:
        Constant Field Values

    - #### FEATURE_SUPPORT

          static final int FEATURE_SUPPORT

      Registration bit for feature support related events
      See Also:
        Constant Field Values

    - #### SWITCHED_TO_PORT

          static final int SWITCHED_TO_PORT

      Registration bit for switched to port
      See Also:
        Constant Field Values

    - #### ALL

          static final int ALL

      All registration bits
      See Also:
        Constant Field Values

  - ### Method Detail

    - #### disconnected

          void disconnected(java.lang.Exception e)

      The Connection has been dropped.

      This event is always sent, mask is ignored.

      Parameters:
        `e` - The exception which caused the disconnect. May be null if disconnect was not caused by an exception.

    - #### connected

          void connected()

      The Connection has successfully been established and the initial handshake has been processed.

      This event is always sent, mask is ignored.

    - #### portListChanged

          java.lang.String portListChanged(java.util.List<? extends IKvmPort> portList)

      The KVM Port List has changed; The event handler can select a port from the list and return it.

      This event is sent when registered with the `PORT_LIST` event mask.

      At the initial connection, the list of KVM ports available (and accessible by the user) on the current KX are returned via this event handler.

      The port list returned at the beginning of the session may be incomplete. Tiering ports are missing and the CIM type are missing. In order to receive a full port list with all ports and information, request it explicitely using `RCCore.requestPortListRefresh()`. Please note that this is supported in KX 3.4 or newer only.

      This event is also used to change the port to connect to. Event handlers may return a unique port ID, different from the one used for the connect method of `RCCore` (`RCCore.connectRCWithUserLogin(String, int, boolean, String, String, String)`, `RCCore.connectRCWithRdmSession(String, int, boolean, String, String, String, String)` or `RCCore.connectRCWithEricKey(String, int, boolean, String, String)`).

      Parameters:
        `portList` - The list of KVM ports on the KX connected to
      Returns:
        Event handlers may return a unique port ID of the KVM port the user wants to connect to. If null is returned, the port ID used in `RCCore.connectRCWithUserLogin(String, int, boolean, String, String, String)`, `RCCore.connectRCWithRdmSession(String, int, boolean, String, String, String, String)` or `RCCore.connectRCWithEricKey(String, int, boolean, String, String)` is used.
      See Also:
        `RCCore.getPortList()`, `RCCore.isPortListRefreshSupported()`, `RCCore.requestPortListRefresh()`, `portListRefreshSupportChanged(boolean)`

    - #### portListRefreshSupportChanged

          void portListRefreshSupportChanged(boolean supported)

      The support for requesting the port list refresh has changed.

      This is only supported in KX 3.4 or newer.

      This event is sent when registered with the `PORT_LIST` event mask.

      Parameters:
        `supported` - true if refreshing the port list is supported, false otherwise
      See Also:
        `RCCore.getPortList()`, `RCCore.isPortListRefreshSupported()`, `RCCore.requestPortListRefresh()`, `portListChanged(List)`

    - #### serverSessionIdChanged

          void serverSessionIdChanged(int serverId)

      The session ID has been received or changed

      This session ID is needed to connect Virtual Media, Audio or SmartCard sessions. The KX needs this ID to connect these sessions to the KVM session.

      This event is sent when registered with the `SERVER_ID` event mask.

      Parameters:
        `serverId` - The server session ID
      See Also:
        `RCCore.getServerSessionId()`

    - #### connectedUsersChanged

          void connectedUsersChanged(int users)

      The number of connected users has changed

      This event is sent when registered with the `CONNECTED_USERS` event mask.

      Parameters:
        `users` - The number of users connected to that port
      See Also:
        `RCCore.getConnectedUsers()`

    - #### monitorModePermissionChanged

          @Deprecated
          void monitorModePermissionChanged(boolean allowed)

      Deprecated.

      The permission to enter/leave Monitor Only Mode (view-only) has changed

      This event is sent when registered with the `MONITOR_MODE` event mask.

      Parameters:
        `allowed` - Is changing monitor mode allowed?
      See Also:
        `RCCore.hasMonitorModePermission()`

    - #### monitorModeChanged

          @Deprecated
          void monitorModeChanged(boolean monitor)

      Deprecated.

      The Monitor Only Mode (view-only) setting has changed

      This event is sent when registered with the `MONITOR_MODE` event mask.

      Parameters:
        `monitor` - Is the monitor mode active?
      See Also:
        `RCCore.isMonitorMode()`

    - #### exclusiveModePermissionChanged

          @Deprecated
          void exclusiveModePermissionChanged(boolean allowed)

      Deprecated.

      The permission to enter/leave Exclusive Access Mode has changed

      This event is sent when registered with the `EXCLUSIVE_MODE` event mask.

      Parameters:
        `allowed` - Is changing exclusive mode allowed?
      See Also:
        `RCCore.hasExclusiveModePermission()`

    - #### exclusiveModeChanged

          @Deprecated
          void exclusiveModeChanged(boolean exclusive)

      Deprecated.

      The exclusive access setting has changed

      This event is sent when registered with the `EXCLUSIVE_MODE` event mask.

      Parameters:
        `exclusive` - Is the exclusive access active?
      See Also:
        `RCCore.isExclusiveMode()`

    - #### languageChanged

          @Deprecated
          void languageChanged(java.util.Locale language)

      Deprecated.

      The device's language setting has changed

      This event is sent when registered with the `LANGUAGE` event mask.

      Parameters:
        `language` - The language

    - #### protocolVersionChanged

          void protocolVersionChanged(java.lang.String protocolVersion)

      The RFB protocol version has been received or changed

      This event is sent when registered with the `PROTOCOL_VERSION` event mask.

      Parameters:
        `protocolVersion` - The protocol version
      See Also:
        `RCCore.getProtocolVersion()`

    - #### deviceNameChanged

          void deviceNameChanged(java.lang.String deviceName)

      The name of the device connected to has been received or changed

      This event is sent when registered with the `DEVICE_NAME` event mask.

      Parameters:
        `deviceName` - The name of the device connected to
      See Also:
        `RCCore.getDeviceName()`

    - #### incomingTrafficSpeed

          void incomingTrafficSpeed(int speed)

      Incoming traffic speed

      This event is emitted every second and reports the network data rate (incoming) in bytes per second.

      This event is sent when registered with the `STATUS_INFO` event mask.

      Parameters:
        `speed` - The incoming network traffic in bytes per second
      See Also:
        `RCCore.getIncomingTrafficSpeed()`

    - #### outgoingTrafficSpeed

          void outgoingTrafficSpeed(int speed)

      Outgoing traffic speed

      This event is emitted every second and reports the network data rate (outgoing) in bytes per second.

      This event is sent when registered with the `STATUS_INFO` event mask.

      Parameters:
        `speed` - The outgoing network traffic in bytes per second
      See Also:
        `RCCore.getOutgoingTrafficSpeed()`

    - #### framesPerSecond

          void framesPerSecond(int frames)

      Frames per second decoded by the KVM protocol

      This event is emitted every second and reports the number of processed video frames in the last second.

      This event is sent when registered with the `STATUS_INFO` event mask.

      Parameters:
        `frames` - The number of decoded video frames in the last second
      See Also:
        `RCCore.getFramesPerSecond()`

    - #### chatWelcomeChanged

          @Deprecated
          void chatWelcomeChanged(java.lang.String welcome)

      Deprecated.

      The Chat Welcome message has changed.

      This event is sent when registered with the `CHAT` event mask.

      Parameters:
        `welcome` - the chat welcome message

    - #### newChatMessage

          @Deprecated
          void newChatMessage(java.lang.String message)

      Deprecated.

      A new chat message has been received.

      This event is sent when registered with the `CHAT` event mask.

      Parameters:
        `message` - the chat message received

    - #### cimLanguageOptionsSupported

          void cimLanguageOptionsSupported(boolean supported)

      CIM options supported

      Used in products where there is no CIM (like KX-101).

      Informs whether the special macro Ctrl+NumLock is supported by CIM or not.

      This event is sent when registered with the `CIM_LANG_OPTION` event mask.

      Parameters:
        `supported` - Is the CIM options supported?
      See Also:
        `RCCore.isCimLanguageOptionsSupported()`

    - #### ethernetGigabitSupported

          void ethernetGigabitSupported(boolean supported)

      Gigabit ethernet support

      Informs whether Gigabit ethernet is supported or not. This is not supported for KX2-101

      This event is sent when registered with the `ETH_GIGABIT_SUPPORT` event mask.

      Parameters:
        `supported` - Is Gigabit Ethernet supported?
      See Also:
        `RCCore.isEthernetGigabitSupported()`

    - #### ericSessionIdChanged

          void ericSessionIdChanged(java.lang.String ericSessionId)

      The eric session ID has been received or changed

      This session ID may be used to authenticate Virtual Media, Audio or other sessions. Using the "eric session ID" is the preferred way for authenticating these sessions which are then "bound" to the KVM session in regards to session timeout, connected users overview etc.

      It is only sent to the client if username/password authentication is used for the KVM session

      This is only sent on KX3 3.2 firmware and newer or in KX4.

      This event is sent when registered with the `ERIC_SESSION_ID_CHANGED` event mask.

      Parameters:
        `ericSessionId` - The eric session ID
      See Also:
        `RCCore.getEricSessionId()`

    - #### licenseFeatureSupportChanged

          void licenseFeatureSupportChanged(java.lang.String feature,
                                            boolean supported)

      Licensed features have changed

      Some features (e.g. "smartcard" or "audio" are not available on LX devices. Therefore, a licensing mechanism is available which reports whether these features are available or not.

      This event is sent when registered with the `LICENSE_SUPPORT` event mask.

      Parameters:
        `feature` - The name of the feature
        `supported` - Is the feature available (licensed) or not?
      See Also:
        `RCCore.isFeatureLicensed(String)`

    - #### powerControlEnabledChanged

          void powerControlEnabledChanged(boolean enabled)

      Power control enabled has changed

      It depends on some KX settings whether Power Control for a port is supported or not. This event is used to inform the client about that.

      This event is sent when registered with the `POWER_CONTROL` event mask.

      Parameters:
        `enabled` - Is Power Control supported for the port connected to?
      See Also:
        `RCCore.isPowerControlEnabled()`, `RCCore.performPowerControl(nn.pp.rccore.RCCore.PowerControlOperations)`

    - #### hideClientMenuEnforcedChanged

          void hideClientMenuEnforcedChanged(boolean enforced)

      The setting whether hiding the client's tool bar and menu bar is enforced by configuration has changed

      This event is sent when registered with the `HIDE_TOOLBAR` event mask.

      Parameters:
        `enforced` - true if hiding the client's toolbar and menu bar is enforced, false otherwise
      See Also:
        `RCCore.isHideClientMenuEnforced()`

    - #### portScanSupportChanged

          void portScanSupportChanged(boolean supported)

      The support for the Port Scan feature has changed

      This event is sent when registered with the `FEATURE_SUPPORT` event mask.

      Parameters:
        `supported` - true if the Port Scan feature is supported, false otherwise
      See Also:
        `RCCore.isPortScanSupported()`

    - #### switchedToPort

          void switchedToPort(java.lang.String portId)

      Successfully switched to a target port.

      This event is sent when registered with the `SWITCHED_TO_PORT` event mask.

      Parameters:
        `portId` - the Port ID switched to

Copyright © 2025 Raritan Inc. All Rights Reserved.