uk.me.jstott.jcoord
Class UTMRef

java.lang.Object
  extended by uk.me.jstott.jcoord.UTMRef

public class UTMRef
extends java.lang.Object

Class to represent a UTM reference (c) 2006 Jonathan Stott Created on 11-Feb-2006

Since:
1.0
Version:
1.0
Author:
Jonathan Stott

Constructor Summary
UTMRef(double easting, double northing, char latZone, int lngZone)
          Create a new UTM reference object.
 
Method Summary
 double getEasting()
          Get the easting.
 char getLatZone()
          Get the latitude zone character.
 int getLngZone()
          Get the longitude zone number.
 double getNorthing()
          Get the northing.
static char getUTMLatitudeZoneLetter(double latitude)
          Work out the UTM latitude zone from the latitude.
 LatLng toLatLng()
          Convert this UTM reference to a latitude and longitude.
 java.lang.String toString()
          Convert this UTM reference to a String representation for printing out.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

UTMRef

public UTMRef(double easting,
              double northing,
              char latZone,
              int lngZone)
Create a new UTM reference object.

Parameters:
easting - the easting
northing - the northing
latZone - the latitude zone character
lngZone - the longitude zone number
Since:
1.0
Method Detail

toLatLng

public LatLng toLatLng()
Convert this UTM reference to a latitude and longitude.

Returns:
the converted latitude and longitude
Since:
1.0

getUTMLatitudeZoneLetter

public static char getUTMLatitudeZoneLetter(double latitude)
Work out the UTM latitude zone from the latitude.

Parameters:
latitude - the latitude to find the UTM latitude zone for
Returns:
the UTM latitude zone for the given latitude
Since:
1.0

toString

public java.lang.String toString()
Convert this UTM reference to a String representation for printing out.

Overrides:
toString in class java.lang.Object
Returns:
a String representation of this UTM reference
Since:
1.0

getEasting

public double getEasting()
Get the easting.

Returns:
the easting
Since:
1.0

getNorthing

public double getNorthing()
Get the northing.

Returns:
the northing
Since:
1.0

getLatZone

public char getLatZone()
Get the latitude zone character.

Returns:
the latitude zone character
Since:
1.0

getLngZone

public int getLngZone()
Get the longitude zone number.

Returns:
the longitude zone number
Since:
1.0