-
public interface NIMMSTADeviceEventHandlerInterface to handle events from a NIMMSTA Device.
For every function the event handler will receive a reference to the NIMMSTADevice that created the event. This reference can then be used to handle the event, for example by turning on the LED or triggering a vibration.
-
-
Method Summary
Modifier and Type Method Description UnitdidConnectAndInit(NIMMSTADevice device)Called when the connection has been established successfully. UnitdidDisconnect(NIMMSTADevice device, String reason)The device was disconnected. UnitdidScanBarcode(NIMMSTADevice device, Barcode barcode)Event is called if a barcode was scanned. UnitdidClickButton(NIMMSTADevice device, String button)Event is called if a button was clicked on the screen. UnitdidStartCharging(NIMMSTADevice device)Event is called if the device starts charging. UnitdidStopCharging(NIMMSTADevice device)Event is called if the device stops charging. UnitbatteryLevelChanged(NIMMSTADevice device, Integer newBatteryLevel)Evert is called if the battery level changes. UnitdidTouch(NIMMSTADevice device, Double x, Double y)Event is called if the screen was touched. UnitdidTrigger(NIMMSTADevice device)Event is called if the trigger was triggered. UnitdidDoubleTrigger(NIMMSTADevice device)Event is called if the trigger was double triggered. UnitdidTripleTrigger(NIMMSTADevice device)Event is called if the trigger was triple triggered. UnitsoftwareUpdateProgress(NIMMSTADevice device, Integer progressPercent)Software update progress handler. -
-
Method Detail
-
didConnectAndInit
Unit didConnectAndInit(NIMMSTADevice device)
Called when the connection has been established successfully. The API is now ready to receive any requests and the device is ready to execute any responses.
- Parameters:
device- NIMMSTADevice
-
didDisconnect
Unit didDisconnect(NIMMSTADevice device, String reason)
The device was disconnected.
- Parameters:
device- NIMMSTADevicereason- Reason for the disconnect
-
didScanBarcode
Unit didScanBarcode(NIMMSTADevice device, Barcode barcode)
Event is called if a barcode was scanned.
- Parameters:
device- NIMMSTADevicebarcode- Scanned barcode String
-
didClickButton
Unit didClickButton(NIMMSTADevice device, String button)
Event is called if a button was clicked on the screen.
- Parameters:
device- NIMMSTADevicebutton- String that was clicked
-
didStartCharging
Unit didStartCharging(NIMMSTADevice device)
Event is called if the device starts charging.
- Parameters:
device- NIMMSTADevice
-
didStopCharging
Unit didStopCharging(NIMMSTADevice device)
Event is called if the device stops charging.
- Parameters:
device- NIMMSTADevice
-
batteryLevelChanged
Unit batteryLevelChanged(NIMMSTADevice device, Integer newBatteryLevel)
Evert is called if the battery level changes.
- Parameters:
device- NIMMSTADevicenewBatteryLevel- New battery level in percent
-
didTouch
Unit didTouch(NIMMSTADevice device, Double x, Double y)
Event is called if the screen was touched. Keep in mind that this event is not triggered if a button was touched.
- Parameters:
device- NIMMSTADevicex- X coordinate on the screeny- Y coordinate on the screen
-
didTrigger
Unit didTrigger(NIMMSTADevice device)
Event is called if the trigger was triggered.
- Parameters:
device- NIMMSTADevice
-
didDoubleTrigger
Unit didDoubleTrigger(NIMMSTADevice device)
Event is called if the trigger was double triggered.
- Parameters:
device- NIMMSTADevice
-
didTripleTrigger
Unit didTripleTrigger(NIMMSTADevice device)
Event is called if the trigger was triple triggered.
- Parameters:
device- NIMMSTADevice
-
softwareUpdateProgress
Unit softwareUpdateProgress(NIMMSTADevice device, Integer progressPercent)
Software update progress handler. Is invoked when a SoftwareUpdate is sent to the device and progress was made.
- Parameters:
device- NIMMSTADeviceprogressPercent- Int
-
-
-
-