All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.mindee.geometry.Point Maven / Gradle / Ivy

There is a newer version: 4.21.0
Show newest version
package com.mindee.geometry;

import lombok.Builder;
import lombok.Value;
import lombok.extern.jackson.Jacksonized;

/**
 * A relative set of coordinates (X, Y) on the document.
 */
@Value
public class Point {
  Double x;
  Double y;

  @Builder
  @Jacksonized
  public Point(Double x, Double y) {
    this.x = x;
    this.y = y;
  }

  @Override
  public boolean equals(Object object) {
    if (this == object) {
      return true;
    }
    if (object == null || this.getClass() != object.getClass()) {
      return false;
    }
    Point point = (Point) object;
    return this.x.equals(point.x) && this.y.equals(point.y);
  }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy