Package io.rong.imlib

## Enum RongIMClient.ConnectionStatusListener.ConnectionStatus

- All Implemented Interfaces:

      public enum RongIMClient.ConnectionStatusListener.ConnectionStatus

  连接状态枚举。

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Class | Description
    --- | --- | ---

  - ### Field Summary

    Fields
    Modifier and Type | Field | Description
    --- | --- | ---

  - ### Constructor Summary

    Constructors
    Constructor | Description
    --- | ---

  - ### Enum Constant Summary

    Enum Constants
    Enum Constant | Description
    --- | ---
    `NETWORK_UNAVAILABLE` | 网络不可用。
    `CONNECTED` | 连接成功。
    `CONNECTING` | 连接中。
    `UNCONNECTED` | 未连接。
    `KICKED_OFFLINE_BY_OTHER_CLIENT` | 用户账户在其他设备登录，本机会被踢掉线。
    `TOKEN_INCORRECT` | Token 不正确。
    `CONN_USER_BLOCKED` | 用户被开发者后台封禁
    `SIGN_OUT` | 用户主动调用 disconnect 或 logout 接口断开连接
    `SUSPEND` | 连接暂时挂起（多是由于网络问题导致），SDK 会在合适时机进行自动重连
    `TIMEOUT` | 自动连接超时，SDK 将不会继续连接，用户需要做超时处理，再自行调用 connectWithToken 接口进行连接
    `CONNECTION_STATUS_PROXY_UNAVAILABLE` |
    `USER_LOGOUT` | 用户已销户

  - ### Method Summary

    Modifier and Type | Method | Description
    --- | --- | ---
    `static RongIMClient.ConnectionStatusListener.ConnectionStatus` | `valueOf(int code)` |
    `int` | `getValue()` | 获取状态代码值。
    `String` | `getMessage()` | 获取状态消息。
    `static Array<RongIMClient.ConnectionStatusListener.ConnectionStatus>` | `values()` | Returns an array containing the constants of this enum type, in the order they're declared.
    `static RongIMClient.ConnectionStatusListener.ConnectionStatus` | `valueOf(String name)` | Returns the enum constant of this type with the specified name.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

  - ### Method Detail

    - #### valueOf

           static RongIMClient.ConnectionStatusListener.ConnectionStatus valueOf(int code)

    - #### getValue

           int getValue()

      获取状态代码值。

      Returns:

        状态代码值。

    - #### getMessage

           String getMessage()

      获取状态消息。

      Returns:

        状态消息。

    - #### values

           static Array<RongIMClient.ConnectionStatusListener.ConnectionStatus> values()

      Returns an array containing the constants of this enum type, in the order they're declared. This method may be used to iterate over the constants.

      Returns:

        an array containing the constants of this enum type, in the order they're declared

    - #### valueOf

           static RongIMClient.ConnectionStatusListener.ConnectionStatus valueOf(String name)

      Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)

      Returns:

        the enum constant with the specified name