Package 

Interface USBMonitor.OnDeviceConnectListener

    • Method Summary

      Modifier and Type Method Description
      abstract void onAttach(UsbDevice device) called when device attached
      abstract void onDetach(UsbDevice device) called when device detach(after onDeviceClose)
      abstract void onDeviceOpen(UsbDevice device, USBMonitor.UsbControlBlock ctrlBlock, boolean createNew) called after device opened
      abstract void onDeviceClose(UsbDevice device, USBMonitor.UsbControlBlock ctrlBlock) called when USB device removed or its power off (this callback is called after device closing)
      abstract void onCancel(UsbDevice device) called when canceled or could not get permission from user
      void onError(UsbDevice device, USBMonitor.USBException e)
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • onAttach

         abstract void onAttach(UsbDevice device)

        called when device attached

      • onDetach

         abstract void onDetach(UsbDevice device)

        called when device detach(after onDeviceClose)

      • onDeviceClose

         abstract void onDeviceClose(UsbDevice device, USBMonitor.UsbControlBlock ctrlBlock)

        called when USB device removed or its power off (this callback is called after device closing)

      • onCancel

         abstract void onCancel(UsbDevice device)

        called when canceled or could not get permission from user