org.osgeo.proj4j.util.IntPolarCoordinate Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of geotrellis-proj4_2.11 Show documentation
Show all versions of geotrellis-proj4_2.11 Show documentation
GeoTrellis is an open source geographic data processing engine for high performance applications.
package org.osgeo.proj4j.util;
import java.io.Serializable;
public final class IntPolarCoordinate implements Serializable {
public int lam, phi;
public IntPolarCoordinate(IntPolarCoordinate that) {
this(that.lam, that.phi);
}
public IntPolarCoordinate(int lam, int phi) {
this.lam = lam;
this.phi = phi;
}
@Override
public String toString() {
return String.format("ILP %x:%x", lam, phi);
}
@Override
public int hashCode() {
return lam | (17 * phi);
}
@Override
public boolean equals(Object that) {
if (that instanceof IntPolarCoordinate) {
IntPolarCoordinate c = (IntPolarCoordinate) that;
return lam == c.lam && phi == c.phi;
} else {
return false;
}
}
}