public abstract class SupportBaseBluetoothActivity extends AppCompatActivity implements SimpleBluetoothListener
| Constructor and Description |
|---|
SupportBaseBluetoothActivity() |
| Modifier and Type | Method and Description |
|---|---|
SimpleBluetooth |
getSimpleBluetooth() |
protected void |
onActivityResult(int requestCode,
int resultCode,
android.content.Intent data) |
void |
onBluetoothEnabled()
This is always called by the activity and indicates that bluetooth is now enabled.
|
protected void |
onCreate(android.os.Bundle savedInstanceState) |
protected void |
onDestroy() |
void |
onDeviceSelected(java.lang.String macAddress)
This method is called after you call {#requestScan} and a device is selected from the list.
|
void |
requestScan()
Call this to request a scan and connect to a device.
|
void |
sendData(java.lang.String data)
Sends data to the currently connected device.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitonBluetoothDataReceived, onDeviceConnected, onDeviceDisconnected, onDiscoveryFinished, onDiscoveryStartedprotected void onCreate(android.os.Bundle savedInstanceState)
protected void onActivityResult(int requestCode,
int resultCode,
android.content.Intent data)
public void onBluetoothEnabled()
public void onDeviceSelected(java.lang.String macAddress)
macAddress, - the macAddress of the selected device.public void sendData(java.lang.String data)
data - the string to send to the device.public void requestScan()
protected void onDestroy()
public SimpleBluetooth getSimpleBluetooth()