Sensors constructor

Sensors(
  1. Map data
)

Implementation

Sensors(Map data) {
  this.platform = data["platform"];
  this.accelerometer = data["accelerometer"];
  this.gyroscope = data["gyroscope"];
  this.magentometer = data["magnetometer"];
  if (data["motion_hardware"] != null) {
    this.motionHardware = data["motion_hardware"];
  }
  if (data["significant_motion"] != null) {
    this.significantMotion = data["significant_motion"];
  }
}