ucar.unidata.geoloc
Class EarthEllipsoid

java.lang.Object
  extended by ucar.unidata.geoloc.Earth
      extended by ucar.unidata.geoloc.EarthEllipsoid

public final class EarthEllipsoid
extends Earth

Type-safe enumeration of Earth Ellipsoids. Follows EPSG.

Author:
john caron
See Also:
http://www.epsg.org/, "http://www.epsg.org/"

Field Summary
static EarthEllipsoid Airy1830
          Airy 1830 ellipsoid from EPSG database version 6.14.
static EarthEllipsoid WGS84
          Ellipsoid for WGS84 (edavis - correct 1/f as per EPSG database ver 6.14)
 
Method Summary
 boolean equals(java.lang.Object o)
          Objects with same name are equal.
static java.util.Collection<EarthEllipsoid> getAll()
          get a collection of all defined EarthEllipsoid objects
 int getEpsgId()
          EPSG id
 java.lang.String getName()
          EPSG name
static EarthEllipsoid getType(int epsgId)
          Find the EarthEllipsoid that matches this EPSG Id.
static EarthEllipsoid getType(java.lang.String name)
          Find the EarthEllipsoid that matches this name.
 int hashCode()
          Override Object.hashCode() to be consistent with this equals.
 java.lang.String toString()
          Same as EPSG name
 
Methods inherited from class ucar.unidata.geoloc.Earth
getEccentricity, getFlattening, getMajor, getMinor, getRadius
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

WGS84

public static final EarthEllipsoid WGS84
Ellipsoid for WGS84 (edavis - correct 1/f as per EPSG database ver 6.14)


Airy1830

public static final EarthEllipsoid Airy1830
Airy 1830 ellipsoid from EPSG database version 6.14.

Method Detail

getAll

public static java.util.Collection<EarthEllipsoid> getAll()
get a collection of all defined EarthEllipsoid objects

Returns:
all defined EarthEllipsoid objects

getType

public static EarthEllipsoid getType(java.lang.String name)
Find the EarthEllipsoid that matches this name.

Parameters:
name - : name to match
Returns:
EarthEllipsoid or null if no match.

getType

public static EarthEllipsoid getType(int epsgId)
Find the EarthEllipsoid that matches this EPSG Id.

Parameters:
epsgId - : epsg Id to match
Returns:
EarthEllipsoid or null if no match.

getName

public java.lang.String getName()
EPSG name

Returns:
the EPSG name

getEpsgId

public int getEpsgId()
EPSG id

Returns:
the EPSG id

toString

public java.lang.String toString()
Same as EPSG name

Overrides:
toString in class java.lang.Object
Returns:
the EPSG name

hashCode

public int hashCode()
Override Object.hashCode() to be consistent with this equals.

Overrides:
hashCode in class java.lang.Object
Returns:
hashCode

equals

public boolean equals(java.lang.Object o)
Objects with same name are equal.

Overrides:
equals in class java.lang.Object
Parameters:
o - test this for equals
Returns:
+,0,-