ucar.unidata.geoloc
Class EarthLocationImpl

java.lang.Object
  extended by ucar.unidata.geoloc.EarthLocationImpl
All Implemented Interfaces:
EarthLocation
Direct Known Subclasses:
StationImpl

public class EarthLocationImpl
extends Object
implements EarthLocation

A location on the Earth.

Author:
caron

Field Summary
protected  double alt
           
protected  double lat
           
protected  double lon
           
 
Constructor Summary
protected EarthLocationImpl()
           
  EarthLocationImpl(double lat, double lon, double alt)
           
 
Method Summary
 double getAltitude()
          altitude in meters; missing = NaN.
 double getLatitude()
          latitude in decimal degrees north
 LatLonPoint getLatLon()
          Get the lat/lon location
 double getLongitude()
          longitude in decimal degrees east
 boolean isMissing()
          Are either lat or lon missing?
protected  void setAltitude(double alt)
           
protected  void setLatitude(double lat)
           
protected  void setLongitude(double lon)
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

lat

protected double lat

lon

protected double lon

alt

protected double alt
Constructor Detail

EarthLocationImpl

protected EarthLocationImpl()

EarthLocationImpl

public EarthLocationImpl(double lat,
                         double lon,
                         double alt)
Method Detail

getLatitude

public double getLatitude()
latitude in decimal degrees north

Specified by:
getLatitude in interface EarthLocation
Returns:
latitude in decimal degrees north

getLongitude

public double getLongitude()
longitude in decimal degrees east

Specified by:
getLongitude in interface EarthLocation
Returns:
longitude in decimal degrees east

getAltitude

public double getAltitude()
altitude in meters; missing = NaN.

Specified by:
getAltitude in interface EarthLocation
Returns:
altitude in meters; missing = NaN.

getLatLon

public LatLonPoint getLatLon()
Get the lat/lon location

Specified by:
getLatLon in interface EarthLocation
Returns:
lat/lon location

isMissing

public boolean isMissing()
Description copied from interface: EarthLocation
Are either lat or lon missing?

Specified by:
isMissing in interface EarthLocation
Returns:
true if lat or lon is missing

setLatitude

protected void setLatitude(double lat)

setLongitude

protected void setLongitude(double lon)

setAltitude

protected void setAltitude(double alt)

toString

public String toString()
Overrides:
toString in class Object


Copyright © 1999-2011 UCAR/Unidata. All Rights Reserved.