com.sap.conn.jco.monitor

## Interface JCoConnectionData

-     public interface JCoConnectionData

  This class provides some details for an RFC connection.

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static int` | `STATE_ACTIVE` Connection state flag: Connection is active.
    `static int` | `STATE_STATEFUL` Connection state flag: Connection is stateful.

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `String` | `getAbapClient()` Returns the client used in the ABAP system.
    `String` | `getAbapHost()` Returns the host where the current or last call was executed or from where the current or last request was received.
    `String` | `getAbapLanguage()` Returns the language used in the ABAP system.
    `String` | `getAbapSystemNumber()` Returns the system number of the ABAP server where the current or last call was executed or from where the current or last request was received.
    `String` | `getAbapUser()` Returns the user name used in the ABAP system.
    `String` | `getApplicationName()` Returns the application name.
    `long` | `getConnectionHandle()` Returns the connection handle.
    `String` | `getConnectionHandleAsString()` Returns the connection handle as a String.
    `String` | `getConnectionType()` Returns the connection type, which is 'client' or 'server'.
    `String` | `getConvId()` Returns the current conversation id.
    `byte[]` | `getDSRPassport()` Returns the byte representation of the DSR passport.
    `String` | `getDSRPassportAsString()` Returns the DSR passport as a hexadecimal string.
    `String` | `getFunctionModuleName()` Returns the name of the function module that is currently being executed or has been executed as last one.
    `String` | `getGroupName()` Returns the name of the connection group.
    `long` | `getLastActivityTimestamp()` Returns the timestamp of the last activity of the connection.
    `String` | `getLastActivityTimestampAsString(Calendar calendar)` Returns the timestamp of the last activity of the connection as a String.
    `String` | `getProtocol()` Returns the communication protocol.
    `String` | `getSessionId()` Returns the client or server internal session id.
    `int` | `getState()` Returns a flag that indicates the activity state of the connection.
    `String` | `getStateAsString()` Returns the activity state of the connection as String.
    `String` | `getSystemID()` Returns the system id of the ABAP server, to which the connection is established.
    `long` | `getThreadId()` Returns the thread ID of the thread, in which the connection was last used.
    `String` | `getThreadIdAsString()` Returns the thread ID as a String of the thread, in which the connection was last used.
    `String` | `getThreadName()` Returns the thread name of the thread, in which the connection was last used.

- - ### Field Detail

    - #### STATE_ACTIVE

          static final int STATE_ACTIVE

      Connection state flag: Connection is active. This means that the connection is busy with handling a request or executing a function module.
      See Also:
        Constant Field Values

    - #### STATE_STATEFUL

          static final int STATE_STATEFUL

      Connection state flag: Connection is stateful. This means that the back-end context is kept and not destroyed after each request.
      See Also:
        Constant Field Values

  - ### Method Detail

    - #### getProtocol

          String getProtocol()

      Returns the communication protocol.
      Currently this is always 'RFC'.
      Returns:
        communication protocol - at the moment always 'RFC'

    - #### getSessionId

          String getSessionId()

      Returns the client or server internal session id.
      Returns:
        client or server internal session id, if available; `null` otherwise

    - #### getFunctionModuleName

          String getFunctionModuleName()

      Returns the name of the function module that is currently being executed or has been executed as last one.
      Returns:
        the name of the function module that is currently being executed or has been executed as last one

    - #### getDSRPassport

          byte[] getDSRPassport()

      Returns the byte representation of the DSR passport.
      Returns:
        the byte representation of the DSR passport, if available; `null` otherwise

    - #### getConnectionType

          String getConnectionType()

      Returns the connection type, which is 'client' or 'server'.
      Returns:
        the connection type 'client' or 'server'

    - #### getSystemID

          String getSystemID()

      Returns the system id of the ABAP server, to which the connection is established.
      Returns:
        the system id of the ABAP server

    - #### getAbapHost

          String getAbapHost()

      Returns the host where the current or last call was executed or from where the current or last request was received.
      Returns:
        the host where the current or last call was executed or from where the current or last request was received

    - #### getAbapSystemNumber

          String getAbapSystemNumber()

      Returns the system number of the ABAP server where the current or last call was executed or from where the current or last request was received.
      Returns:
        the system number of the ABAP server where the current or last call was executed or from where the current or last request was received

    - #### getAbapClient

          String getAbapClient()

      Returns the client used in the ABAP system.
      Returns:
        the client used in the ABAP system, if available; `null` otherwise

    - #### getAbapUser

          String getAbapUser()

      Returns the user name used in the ABAP system.
      Returns:
        the user name used in the ABAP system, if available; `null` otherwise

    - #### getAbapLanguage

          String getAbapLanguage()

      Returns the language used in the ABAP system.
      Returns:
        the language used in the ABAP system, if available; `null` otherwise

    - #### getConvId

          String getConvId()

      Returns the current conversation id.
      Returns:
        the current conversation id or `null` in case of an inactive server connection

    - #### getApplicationName

          String getApplicationName()

      Returns the application name.
      Returns:
        the application name, if provided by the application or runtime; `null` otherwise

    - #### getGroupName

          String getGroupName()

      Returns the name of the connection group.
      The connection group is either a client pool id or a server group id.
      Returns:
        the name of the connection group; either a client pool id or a server group id

    - #### getState

          int getState()

      Returns a flag that indicates the activity state of the connection.
      The connection activity state is either `STATE_ACTIVE` or `STATE_STATEFUL`.
      Returns:
        a flag that indicates the activity state of the connection

    - #### getLastActivityTimestamp

          long getLastActivityTimestamp()

      Returns the timestamp of the last activity of the connection.
      Returns:
        the last activity timestamp

    - #### getStateAsString

          String getStateAsString()

      Returns the activity state of the connection as String.
      For example: 'ACTIVE|STATEFUL'
      Returns:
        the activity state of the connection as a String

    - #### getDSRPassportAsString

          String getDSRPassportAsString()

      Returns the DSR passport as a hexadecimal string.
      Returns:
        the DSR passport as a hexadecimal string

    - #### getLastActivityTimestampAsString

          String getLastActivityTimestampAsString(Calendar calendar)

      Returns the timestamp of the last activity of the connection as a String.
      For example: '2007-02-28|16:41:59.123'
      Parameters:
        `calendar` - the calender instance to be used for converting the timestamp value into a human readable format
      Returns:
        the last activity timestamp as a String

    - #### getThreadId

          long getThreadId()

      Returns the thread ID of the thread, in which the connection was last used.
      Returns:
        the thread ID of the thread, in which the connection was last used

    - #### getThreadIdAsString

          String getThreadIdAsString()

      Returns the thread ID as a String of the thread, in which the connection was last used.
      Returns:
        the thread ID as a String of the thread, in which the connection was last used

    - #### getThreadName

          String getThreadName()

      Returns the thread name of the thread, in which the connection was last used.
      Returns:
        the thread name of the thread, in which the connection was last used

    - #### getConnectionHandle

          long getConnectionHandle()

      Returns the connection handle.
      The connection handle is unique within the JVM process.
      Returns:
        the connection handle

    - #### getConnectionHandleAsString

          String getConnectionHandleAsString()

      Returns the connection handle as a String.
      The connection handle is unique within the JVM process.
      Returns:
        the connection handle as a String

Copyright © 2019 SAP. All Rights Reserved.