public class AndroidBluetoothDeviceWrapperImpl extends java.lang.Object implements AndroidBluetoothDeviceWrapper
Constructor and Description |
---|
AndroidBluetoothDeviceWrapperImpl(android.bluetooth.BluetoothDevice bluetoothDevice) |
Modifier and Type | Method and Description |
---|---|
void |
connectGatt(android.content.Context context,
boolean autoConnect,
android.bluetooth.BluetoothGattCallback bluetoothGattCallback)
Wraps the Android connectGatt method used to connect and interrogate Bluetooth LE devices
|
java.lang.String |
getAddress()
Adress wrapper
|
android.bluetooth.BluetoothDevice |
getDevice() |
java.lang.String |
getName()
Name wrapper
|
public AndroidBluetoothDeviceWrapperImpl(android.bluetooth.BluetoothDevice bluetoothDevice)
public android.bluetooth.BluetoothDevice getDevice()
getDevice
in interface AndroidBluetoothDeviceWrapper
public java.lang.String getName()
AndroidBluetoothDeviceWrapper
getName
in interface AndroidBluetoothDeviceWrapper
public java.lang.String getAddress()
AndroidBluetoothDeviceWrapper
getAddress
in interface AndroidBluetoothDeviceWrapper
public void connectGatt(android.content.Context context, boolean autoConnect, android.bluetooth.BluetoothGattCallback bluetoothGattCallback)
AndroidBluetoothDeviceWrapper
connectGatt
in interface AndroidBluetoothDeviceWrapper
context
- Android application contextautoConnect
- Whether to directly connect to the remote device (false) or to automatically connect as soon as the remote device becomes available (true)bluetoothGattCallback
- GATT callback handler that will receive asynchronous callbacks