public enum ConnectionState

  1. Object
  2. Enum<ConnectionState>
  3. ConnectionState

ImplementsComparable<ConnectionState>

Lifecycle states of a BlePeripheral connection.

Enum constants

DISCONNECTEDNo connection.
CONNECTINGA BlePeripheral.connect() attempt is in progress.
CONNECTEDThe link is established; GATT operations are available.
DISCONNECTINGA BlePeripheral.disconnect() request is in progress.

Methods

public static ConnectionState[] values()
public static ConnectionState valueOf(String name)

Inherited methods

Enum constant details

DISCONNECTED

DISCONNECTED
No connection. GATT operations fail with BluetoothError.NOT_CONNECTED.

CONNECTING

CONNECTING
A BlePeripheral.connect() attempt is in progress.

CONNECTED

CONNECTED
The link is established; GATT operations are available.

DISCONNECTING

DISCONNECTING
A BlePeripheral.disconnect() request is in progress.

Method details

values

public static ConnectionState[] values()

valueOf

public static ConnectionState valueOf(String name)