bluetooth_state

Creator: coderz1093

Last updated:

0 purchases

bluetooth_state Image
bluetooth_state Images

Languages

Categories

Add to Cart

Description:

bluetooth state

bluetooth_state #
A Plugin Flutter Bluetooth turn off/on
Getting Started #
Install #
Add the following lines in your pubspec.yaml file
bluetooth_state: ^latest_version
copied to clipboard
API #
Is Bluetooth Enable
Future<bool> get isBluetoothEnable async {
try {
return await BluetoothState().isBluetoothEnable;
} catch (e) {
print(e);
throw 'Failed to get is bluetooth enable';
}
}
copied to clipboard
Request Enable Bluetooth
Future<void> requestEnableBluetooth() async {
try {
await BluetoothState.requestEnableBluetooth();
} catch (e) {
print(e);
throw 'Failed to request enable bluetooth';
}
}
copied to clipboard
Request Disable Bluetooth
Future<void> requestDisableBluetooth() async {
try {
await BluetoothState.requestDisableBluetooth();
} catch (e) {
print(e);
throw 'Failed to request disable bluetooth';
}
}
copied to clipboard

License

For personal and professional use. You cannot resell or redistribute these repositories in their original state.

Files In This Product:

Customer Reviews

There are no reviews.