Grabba Driver for Android
Unified driver for Grabba devices on the Android operating system
ButtonAPI.ButtonBehaviour Enum Reference

Description

Enumeration of supported button behaviours.

This enumeration describes the set of button behaviours directly supported by the driver. It applies to the left and right buttons of a connected Grabba device; they may be configured to behave identically or independently.

Public Attributes

 BARCODE_PRESS_TO_SCAN
 Button events control barcode scans in addition to triggering callbacks. More...
 
 CALLBACK_ONLY
 Button events only trigger callbacks (default behaviour) More...
 
 PROXCARD_PRESS_TO_SCAN
 Button events control proxcard/RFID scans in addition to triggering callbacks. More...
 

Member Data Documentation

◆ BARCODE_PRESS_TO_SCAN

BARCODE_PRESS_TO_SCAN

Button events control barcode scans in addition to triggering callbacks.

Pressing the button will trigger a barcode scan if one is not already active. This scan will continue until any of the following conditions are met:

  • The button is released and, if the other button is also configured to trigger barcode scanning, that button is also released
  • A barcode is successfully scanned
  • An error is detected during the scan process (e.g. disconnection from Grabba device)

This behaviour is the equivalent of invoking BarcodeAPI.startScan() when buttons are pressed and BarcodeAPI.stopScan() when buttons are released.

◆ CALLBACK_ONLY

CALLBACK_ONLY

Button events only trigger callbacks (default behaviour)

Pressing or releasing the buttons on the Grabba device has no effect within the driver beyond triggering callbacks to any active ButtonListener objects (including subclasses). Application code may use these events to trigger desired processing, but there is no requirement to do so.

◆ PROXCARD_PRESS_TO_SCAN

PROXCARD_PRESS_TO_SCAN

Button events control proxcard/RFID scans in addition to triggering callbacks.

Pressing the button will trigger a proxcard/RFID scan if one is not already active. This scan will continue until any of the following conditions are met:

  • The button is released and, if the other button is also configured to trigger proxcard/RFID scanning, that button is also released
  • A proxcard or RFID tag is successfully scanned
  • An error is detected during the scan process (e.g. disconnection from Grabba device)

This behaviour is the equivalent of invoking ProxcardAPI.startScan() when buttons are pressed and ProxcardAPI.stopScan() when buttons are released.