Example usage for android.bluetooth BluetoothAdapter STATE_CONNECTING

List of usage examples for android.bluetooth BluetoothAdapter STATE_CONNECTING

Introduction

In this page you can find the example usage for android.bluetooth BluetoothAdapter STATE_CONNECTING.

Prototype

int STATE_CONNECTING

To view the source code for android.bluetooth BluetoothAdapter STATE_CONNECTING.

Click Source Link

Document

The profile is in connecting state

Usage

From source file:Main.java

public static String getStateString(int state) {
    switch (state) {
    case BluetoothAdapter.STATE_CONNECTED:
        return "Connected";
    case BluetoothAdapter.STATE_CONNECTING:
        return "Connecting";
    case BluetoothAdapter.STATE_DISCONNECTED:
        return "Disconnected";
    case BluetoothAdapter.STATE_DISCONNECTING:
        return "Disconnecting";
    case BluetoothAdapter.STATE_OFF:
        return "Off";
    case BluetoothAdapter.STATE_ON:
        return "On";
    case BluetoothAdapter.STATE_TURNING_OFF:
        return "Turning Off";
    case BluetoothAdapter.STATE_TURNING_ON:
        return "Turning On";
    default:/*from   w  w  w  . j a va2s .c  om*/
        return "Unknown";
    }
}