Skip to content
com.iristick.smartglass.core

Class SensorEvent


public abstract class SensorEvent
extends Object
This class represents a Sensor event and holds information such as the sensor's type and the sensor's data.

Field Summary

Modifier and Type Field and Description
Sensor sensor
The sensor that generated this event.
float[] values
The data from the sensor.

Method Summary

Methods inherited from class java.lang.Object

equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Field Detail

sensor

@NonNull
public final Sensor sensor

The sensor that generated this event.

values

@NonNull
public final float[] values

The data from the sensor.

The length and contents of the values array depends on which sensor type is being monitored. See the definitions of the TYPE_* constants in the Sensor class for its interpretation.