Interface IDeviceScanner


public interface IDeviceScanner

Interface for device scanning services.
Implementations of this interface are typically used by sensor drivers to discover sensors connected via USB, bluetooth, zeroconf, etc.

Since:
Feb 6, 2016
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
     
    void
    Scans for any connected device
    void
    startScan(IDeviceScanCallback callback, String idRegex)
    Scans for connected devices with device ID matching the given regex pattern
    This will only generate events when the device ID matches the regex pattern
    void
    Stop the current scan
  • Method Details

    • startScan

      void startScan(IDeviceScanCallback callback)
      Scans for any connected device
      Parameters:
      callback - callback to which scan results are delivered
    • startScan

      void startScan(IDeviceScanCallback callback, String idRegex)
      Scans for connected devices with device ID matching the given regex pattern
      This will only generate events when the device ID matches the regex pattern
      Parameters:
      callback - callback to which scan results are delivered
      idRegex - Regex pattern for filtering on the device ID
    • stopScan

      void stopScan()
      Stop the current scan
    • isScanning

      boolean isScanning()
      Returns:
      true if a scan is in process, false otherwise