Package ej.bluetooth

Class BluetoothAdapter

  • All Implemented Interfaces:
    ej.kf.FeatureStateListener

    public class BluetoothAdapter
    extends java.lang.Object
    implements ej.kf.FeatureStateListener
    • Method Detail

      • enable

        public boolean enable()
      • disable

        public void disable()
      • stateChanged

        public void stateChanged​(@Nullable
                                 ej.kf.Feature feature,
                                 @Nullable
                                 ej.kf.Feature.State previousState)
        Specified by:
        stateChanged in interface ej.kf.FeatureStateListener
      • setConnectionListener

        public void setConnectionListener​(ConnectionListener connectionListener)
      • startAdvertising

        public boolean startAdvertising​(byte[] advertisementData)
      • stopAdvertising

        public boolean stopAdvertising()
      • stopScanning

        public boolean stopScanning()
      • handleScanResult

        public void handleScanResult​(BluetoothAddress deviceAddress,
                                     byte[] advertisementData,
                                     int rssi)
        Not in API.
      • handleScanCompleted

        public void handleScanCompleted()
        Not in API.
      • handleAdvertisementCompleted

        public void handleAdvertisementCompleted()
        Not in API.
      • handleConnectFailed

        public void handleConnectFailed​(BluetoothAddress deviceAddress)
        Not in API.
      • handleConnected

        public void handleConnected​(short connHandle,
                                    BluetoothAddress deviceAddress)
        Not in API.
      • handleDisconnected

        public void handleDisconnected​(short connHandle)
        Not in API.
      • handlePairRequest

        public void handlePairRequest​(short connHandle)
        Not in API.
      • handlePairCompleted

        public void handlePairCompleted​(short connHandle,
                                        boolean success)
        Not in API.
      • handlePasskeyRequest

        public void handlePasskeyRequest​(short connHandle)
        Not in API.
      • handlePasskeyGenerated

        public void handlePasskeyGenerated​(short connHandle,
                                           int passkey)
        Not in API.
      • handleDiscoveryResult

        public void handleDiscoveryResult​(short connHandle,
                                          BluetoothService service)
        Not in API.
      • handleDiscoveryCompleted

        public void handleDiscoveryCompleted​(short connHandle)
        Not in API.
      • handleReadCompleted

        public void handleReadCompleted​(short connHandle,
                                        short attributeHandle,
                                        byte status,
                                        byte[] value)
        Not in API.
      • handleWriteCompleted

        public void handleWriteCompleted​(short connHandle,
                                         short attributeHandle,
                                         byte status)
        Not in API.
      • handleNotificationReceived

        public void handleNotificationReceived​(short connHandle,
                                               short attributeHandle,
                                               byte[] value)
        Not in API.
      • handleReadRequest

        public void handleReadRequest​(short connHandle,
                                      short attributeHandle,
                                      int offset)
        Not in API.
      • handleWriteRequest

        public void handleWriteRequest​(short connHandle,
                                       short attributeHandle,
                                       byte[] value,
                                       short offset,
                                       boolean prepare)
        Not in API.
      • handleExecuteWriteRequest

        public void handleExecuteWriteRequest​(short connHandle,
                                              short attributeHandle,
                                              boolean execute)
        Not in API.
      • handleNotificationSent

        public void handleNotificationSent​(short connHandle,
                                           short attributeHandle,
                                           boolean success)
        Not in API.