Class CoordinateConversion


  • public final class CoordinateConversion
    extends java.lang.Object
    Allows easy conversion between JMapViewer coordinate types and JOSM coordinate types.
    Since:
    12669
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static LatLon coorToLL​(org.openstreetmap.gui.jmapviewer.interfaces.ICoordinate c)
      Converts an ICoordinate to a LatLon instance.
      static org.openstreetmap.gui.jmapviewer.interfaces.IProjected enToProj​(EastNorth en)
      Converts an EastNorth to an IProjected instance.
      static org.openstreetmap.gui.jmapviewer.interfaces.ICoordinate llToCoor​(LatLon ll)
      Converts a LatLon to an ICoordinate instance.
      static EastNorth projToEn​(org.openstreetmap.gui.jmapviewer.interfaces.IProjected p)
      Converts an IProjected to an EastNorth instance.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • enToProj

        public static org.openstreetmap.gui.jmapviewer.interfaces.IProjected enToProj​(EastNorth en)
        Converts an EastNorth to an IProjected instance.
        Parameters:
        en - east/north coordinate
        Returns:
        IProjected instance
      • projToEn

        public static EastNorth projToEn​(org.openstreetmap.gui.jmapviewer.interfaces.IProjected p)
        Converts an IProjected to an EastNorth instance.
        Parameters:
        p - projected coordinate
        Returns:
        EastNorth instance
      • llToCoor

        public static org.openstreetmap.gui.jmapviewer.interfaces.ICoordinate llToCoor​(LatLon ll)
        Converts a LatLon to an ICoordinate instance.
        Parameters:
        ll - latitude/longitude coordinate
        Returns:
        ICoordinate instance
      • coorToLL

        public static LatLon coorToLL​(org.openstreetmap.gui.jmapviewer.interfaces.ICoordinate c)
        Converts an ICoordinate to a LatLon instance.
        Parameters:
        c - coordinate
        Returns:
        LatLon instance