SensorEvent class

Provides a data structure for encapsulating a single 3-axis sensor event sample.

Used for all sensor types (accelerometer, gyroscope, magnetometer) regardless of device.

Holds the 3-axis values x, y, z, and the timestamp when the event occurred. The same class is used for data from all supported sensors.

Constructors

SensorEvent.new(double x, double y, double z, DateTime timestamp)
Creates a SensorEvent with the given x, y, z values and timestamp.

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
timestamp DateTime
final
x double
final
y double
final
z double
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
Returns a string representation of the sensor event.
override

Operators

operator ==(Object other) bool
The equality operator.
inherited