operator == method

  1. @override
bool operator ==(
  1. Object other
)
override

Two FlSpot are equal if their x and y are equal.

Implementation

@override
bool operator ==(Object other) {
  if (identical(this, other)) return true;
  if (other is! FlSpot) {
    return false;
  }

  if (x.isNaN && y.isNaN && other.x.isNaN && other.y.isNaN) {
    return true;
  }

  return other.x == x && other.y == y;
}