Class TLcdUTMZone

java.lang.Object
com.luciad.view.map.TLcdUTMZone
All Implemented Interfaces:
Cloneable

public class TLcdUTMZone extends Object implements Cloneable
The TLcdUTMZone extends Object, it represents a UTM-MGRS zone. The TLcdUTMZone is determined by its zoneID, which is a value between 0 and 60.

Due to different values for the false northing for the northern and the southern hemisphere all methods involving calculations require a parameter indicating for which hemisphere the calculations should be performed. Accepted values for the hemisphere are NORTHERN_HEMISPHERE and SOUTHERN_HEMISPHERE.

  • Field Details

    • NORTHERN_HEMISPHERE

      public static final int NORTHERN_HEMISPHERE
      Constant indicating that calculations should be performed for the northern hemisphere.
      See Also:
    • SOUTHERN_HEMISPHERE

      public static final int SOUTHERN_HEMISPHERE
      Constant indicating that calculations should be performed for the southern hemisphere.
      See Also:
  • Constructor Details

    • TLcdUTMZone

      public TLcdUTMZone()
      Constructs a TLcdUTMZone for zone 30.
    • TLcdUTMZone

      public TLcdUTMZone(int aZoneID)
      Constructs a TLcdUTMZone for the given zone ID.
      Parameters:
      aZoneID - the ID of the zone.
    • TLcdUTMZone

      public TLcdUTMZone(int aZoneID, ILcdGeodeticDatum aGeodeticDatum)
  • Method Details

    • getCentralMeridian

      public double getCentralMeridian()
      The centralMeridian is calculated on the basis of the zoneID.
      Returns:
      the centralMeridian of this TLcdUTMZone.
    • getZoneID

      public int getZoneID()
      The zoneID fully identifies the TLcdUTMZone. Its value is located between 0 and 60.
      Returns:
      the zoneID of this TLcdUTMZone.
      See Also:
    • setZoneID

      public void setZoneID(int aZoneID)
      Sets the new zoneID for this TLcdUTMZone.
      Parameters:
      aZoneID - the new zoneID for this TLcdUTMZone.
      See Also:
    • getMaxXYBounds

      public ILcd2DEditableBounds getMaxXYBounds()
      Deprecated.
      use the method that passes the hemisphere. This method calls that method with the norther hemisphere as parameter.
      Calculates the maximal bounds in XY of this TLcdUTMZone. This means that points with coordinates outside of the range of this bounds (i.e. with x larger than the width, or y larger than the height), will certainly be outside this zone. This does not guarantee however that points within these bounds are within this zone.
      Returns:
      ILcd2DEditableBounds which represents the maximum bounds.
    • getMaxXYBounds

      public ILcd2DEditableBounds getMaxXYBounds(int aHemiSphere)
      Calculates the maximal bounds in XY of this TLcdUTMZone. This means that points with coordinates outside of the range of this bounds (i.e. with x larger than the width, or y larger than the height), will certainly be outside this zone. This does not guarantee however that points within these bounds are within this zone.
      Returns:
      ILcd2DEditableBounds which represents the maximum bounds.
    • getGeodeticBounds

      public ILcd2DEditableBounds getGeodeticBounds(int aHemisphere)
      Calculates the geodetic bounds of this UTM zone. Geodetic points with coordinates outside of the range of this bounds will certainly be outside this zone. This does not guarantee however that points within these bounds are within this zone.
      Parameters:
      aHemisphere - the hemisphere
      Returns:
      ILcd2DEditableBounds which represents the maximum bounds.
    • calculateXBoundsSFCT

      public void calculateXBoundsSFCT(double aY, double[] aLimitSFCT) throws TLcdOutOfBoundsException
      Deprecated.
      use the method with the hemisphere parameter. This method calls the method, passing the northern hemisphere.
      Given a northing aY, calculates the west and east bounds of this TLcdUTMZone.
      Parameters:
      aY - the northing at which to calculate the bounds.
      aLimitSFCT - array where the west and east bounds will be stored, respectively at index 0 and at index 1.
      Throws:
      TLcdOutOfBoundsException - if the specified coordinate is out of bounds.
    • calculateXBoundsSFCT

      public void calculateXBoundsSFCT(double aX, double aY, double[] aLimitSFCT) throws TLcdOutOfBoundsException
      Deprecated.
      Given an easting aX and a northing aY, calculates the west and east bounds of this TLcdUTMZone at the northing level aY,.
      Parameters:
      aX - the easting of the point which' northing is aY.
      aY - the northing at which to calculate the bounds.
      aLimitSFCT - array where the west and east bounds will be stored, respectively at index 0 and at index 1.
      Throws:
      TLcdOutOfBoundsException - if the specified coordinate is out of bounds.
    • calculateXBoundsSFCT

      public void calculateXBoundsSFCT(double aY, double[] aLimitSFCT, int aHemiSphere) throws TLcdOutOfBoundsException
      Calculates the west and east bounds of this TLcdUTMZone at the northing aY.
      Parameters:
      aY - the northing at which to calculate the bounds.
      aLimitSFCT - array where the west and east bounds will be stored, respectively at index 0 and at index 1.
      Throws:
      TLcdOutOfBoundsException - if the specified coordinate is out of bounds.
    • calculateXBoundsSFCT

      public void calculateXBoundsSFCT(double aX, double aY, double[] aLimitSFCT, int aHemiSphere) throws TLcdOutOfBoundsException
      Given a northing aY, calculates the west and east bounds of this TLcdUTMZone in grid coordinates.
      Parameters:
      aY - the northing at which to calculate the bounds.
      aLimitSFCT - array where the west and east bounds will be stored, respectively at index 0 and at index 1.
      Throws:
      TLcdOutOfBoundsException - if the specified coordinate is out of bounds.
    • contains

      public boolean contains(double aX, double aY) throws TLcdOutOfBoundsException
      Deprecated.
      use the method with the hemisphere.
      Returns true if the coordinate is within the UTM zone, false otherwise..
      Parameters:
      aX - the x-coordinate.
      aY - the y-coordinate.
      Returns:
      true if the coordinate is within the UTM zone, false otherwise.
      Throws:
      TLcdOutOfBoundsException - if the coordinate is out of bounds.
    • contains

      public boolean contains(double aX, double aY, int aHemiSphere) throws TLcdOutOfBoundsException
      Returns true if the coordinate is within the UTM zone, false otherwise..
      Parameters:
      aX - the x-coordinate.
      aY - the y-coordinate.
      Returns:
      true if the coordinate is within the UTM zone, false otherwise.
      Throws:
      TLcdOutOfBoundsException - if the coordinate is out of bounds.
    • grid2lonlatSFCT

      public void grid2lonlatSFCT(double aX, double aY, ILcd3DEditablePoint a3DEditablePointSFCT) throws TLcdOutOfBoundsException
      Deprecated.
      use the method with the hemisphere parameter. This method calls that method with the northern hemisphere as parameter.
      Transformation of grid coordinate to LonLatHeight coordinate.
      Parameters:
      aX - x-value of the grid coordinate.
      aY - y-value of the grid coordinate.
      a3DEditablePointSFCT - the resulting lon-lat-height coordinate as side effect.
      Throws:
      TLcdOutOfBoundsException - The grid point (aX,aY) is outside the valid area of the projection.
    • grid2lonlatSFCT

      public void grid2lonlatSFCT(double aX, double aY, int aHemiSphere, ILcd3DEditablePoint a3DEditablePointSFCT) throws TLcdOutOfBoundsException
      Transformation of grid coordinate to LonLatHeight coordinate.
      Parameters:
      aX - x-value of the grid coordinate.
      aY - y-value of the grid coordinate.
      a3DEditablePointSFCT - the resulting lon-lat-height coordinate as side effect.
      Throws:
      TLcdOutOfBoundsException - The grid point (aX,aY) is outside the valid area of the projection.
    • grid2worldSFCT

      public void grid2worldSFCT(double aX, double aY, ILcd3DEditablePoint a3DEditablePointSFCT) throws TLcdOutOfBoundsException
      Deprecated.
      Transformation of grid coordinate to world coordinate.
      Parameters:
      aX - x-value of the grid coordinate.
      aY - y-value of the grid coordinate.
      a3DEditablePointSFCT - the resulting world coordinate as side effect.
      Throws:
      TLcdOutOfBoundsException - The grid point (aX,aY) is outside the valid area of the projection.
    • grid2worldSFCT

      public void grid2worldSFCT(double aX, double aY, int aHemiSphere, ILcd3DEditablePoint a3DEditablePointSFCT) throws TLcdOutOfBoundsException
      Transformation of grid coordinate to world coordinate.
      Parameters:
      aX - x-value of the grid coordinate.
      aY - y-value of the grid coordinate.
      a3DEditablePointSFCT - the resulting world coordinate as side effect.
      Throws:
      TLcdOutOfBoundsException - The grid point (aX,aY) is outside the valid area of the projection.
    • world2gridSFCT

      public void world2gridSFCT(ILcdPoint aWorldPoint, ILcd2DEditablePoint aXYPointSFCT) throws TLcdOutOfBoundsException
      Deprecated.
      Transformation of world coordinate to grid coordinate.
      Parameters:
      aWorldPoint - the world coordinate.
      aXYPointSFCT - the resulting grid coordinate as side effect.
      Throws:
      TLcdOutOfBoundsException - The world point (aX,aY) is outside the valid area of the projection.
    • world2gridSFCT

      public void world2gridSFCT(ILcdPoint aWorldPoint, int aHemiSphere, ILcd2DEditablePoint aXYPointSFCT) throws TLcdOutOfBoundsException
      Transformation of world coordinate to grid coordinate.
      Parameters:
      aWorldPoint - the world coordinate.
      aXYPointSFCT - the resulting grid coordinate as side effect.
      Throws:
      TLcdOutOfBoundsException - The world point (aX,aY) is outside the valid area of the projection.
    • lonlat2gridSFCT

      public void lonlat2gridSFCT(double aLon, double aLat, ILcd2DEditablePoint aXYPointSFCT) throws TLcdOutOfBoundsException
      Deprecated.
      Transformation of lon-lat coordinate to grid coordinate.
      Parameters:
      aLon - the longitude of the coordinate.
      aLat - the latitude of the coordinate.
      aXYPointSFCT - the resulting grid coordinate as side effect.
      Throws:
      TLcdOutOfBoundsException - The lon-lat point (aLon,aLat) is outside the valid area of the projection.
    • lonlat2gridSFCT

      public void lonlat2gridSFCT(double aLon, double aLat, int aHemiSphere, ILcd2DEditablePoint aXYPointSFCT) throws TLcdOutOfBoundsException
      Transformation of lon-lat coordinate to grid coordinate.
      Parameters:
      aLon - the longitude of the coordinate.
      aLat - the latitude of the coordinate.
      aXYPointSFCT - the resulting grid coordinate as side effect.
      Throws:
      TLcdOutOfBoundsException - The lon-lat point (aLon,aLat) is outside the valid area of the projection.
    • calculateLabelsStringSFCT

      public void calculateLabelsStringSFCT(double aX, double aY, String[] aString)
      Deprecated.
      use the method with the hemisphere parameter. This method calls that method passing the northern hemisphere.
      Returns the labels of the four 100km zones surrounding a UTM-MGRS 100km grid point of the TLcdUTMZone.
      Parameters:
      aX - the easting of the grid point.
      aY - the northing of the grid point.
      aString - an array of String which will contain the resulting labels: aString[0] : zone to the north-east of the grid point. aString[1] : zone to the south-east of the grid point. aString[2] : zone to the south-west of the grid point. aString[3] : zone to the north-west of the grid point.
    • calculateLabelsStringSFCT

      public void calculateLabelsStringSFCT(double aX, double aY, int aHemiSphere, String[] aString)
      Returns the labels of the four 100km zones surrounding a UTM-MGRS 100km grid point of the TLcdUTMZone.
      Parameters:
      aX - the easting of the grid point.
      aY - the northing of the grid point.
      aString - an array of String which will contain the resulting labels: aString[0] : zone to the north-east of the grid point. aString[1] : zone to the south-east of the grid point. aString[2] : zone to the south-west of the grid point. aString[3] : zone to the north-west of the grid point.
    • getUTMGrid

      public TLcdUTMGrid getUTMGrid()
      Returns an ILcdModelReference representing the grid of the UTM zone.
      Returns:
      an ILcdModelReference representing the grid of the UTM zone.
    • getUTMGridReference

      public TLcdUTMGrid getUTMGridReference(int aHemiSphere)
    • clone

      public Object clone()
      Overrides:
      clone in class Object