Class Coordinate



  • public class Coordinate
    extends Object
    • Field Detail

      • lon

        public double lon
      • lat

        public double lat
    • Constructor Detail

      • Coordinate

        public Coordinate(double lon,
                          double lat)
        Create a new Coordinate.
        Parameters:
        lon - the longitude.
        lat - the latitude.
    • Method Detail

      • getLongitude

        public double getLongitude()
        Returns:
        this coordinate's longitude.
      • getLatitude

        public double getLatitude()
        Returns:
        this coordinate's latitude.
      • toString

        public String toString()
      • mean

        public static Coordinate mean(Collection<Coordinate> coords)
        Calculate the mean of this collection of coordinates.
        Parameters:
        coords - a collection of coordinates.
        Returns:
        the mean of the given coordinates.