operator == method

bool operator == (
  1. Object o
)
override

An equals (==) operator for comparing two data points This makes it possible to remove duplicate data points.

Implementation

bool operator ==(Object o) {
  return o is HealthDataPoint &&
      this.value == o.value &&
      this.unit == o.unit &&
      this.dateFrom == o.dateFrom &&
      this.dateTo == o.dateTo &&
      this.type == o.type &&
      this.platform == o.platform &&
      this.deviceId == o.deviceId;
}