Jeospace API

org.jeospace.coordinate
Class Ellipsoidal

java.lang.Object
  extended byorg.jeospace.coordinate.Polar
      extended byorg.jeospace.coordinate.Ellipsoidal

public class Ellipsoidal
extends Polar

A concrete subclass of Polar, Ellipsoidal represents a form of a polar coordinate that is referenced to an Ellipsoid. Ellipsoidal coordinates are commonly used in geographic applications.

In extending Polar:

Note: An Ellipsoidal coordinate with it's Ellipsoid parameter set to null will perform identically to a Spherical coordinate.

For further reference see:
Coordinate Systems Overview
Coordinate Systems - A Deeper Understanding

Version:
$Revision: 1.1.1.1 $
Author:
Rex Melton
See Also:
Longitude, Latitude, Length, Ellipsoid, Cartesian, Spherical, Polar

Field Summary
 
Fields inherited from class org.jeospace.coordinate.Polar
distance, latitude, longitude
 
Constructor Summary
Ellipsoidal()
          Construct an Ellipsoidal coordinate object with default parameters.
Ellipsoidal(Cartesian cartesian, Ellipsoid ellipsoid)
          Construct an Ellipsoidal coordinate object that cooresponds to the given Cartesian coordinate.
Ellipsoidal(double longitudeDegrees, double latitudeDegrees, Length elevation)
          Construct an Ellipsoidal coordinate object with the given parameters from the given objects.
Ellipsoidal(double longitudeDegrees, double latitudeDegrees, Length elevation, Ellipsoid ellipsoid)
          Construct an Ellipsoidal coordinate object with the given parameters from the given objects.
Ellipsoidal(Ellipsoid ellipsoid)
          Construct an Ellipsoidal coordinate object with default coordinate parameters and the specified ellipsoid.
Ellipsoidal(Longitude longitude, Latitude latitude, Length elevation)
          Construct an Ellipsoidal coordinate object.
Ellipsoidal(Longitude longitude, Latitude latitude, Length elevation, Ellipsoid ellipsoid)
          Construct an Ellipsoidal coordinate object.
Ellipsoidal(Polar polar)
          Construct an Ellipsoidal coordinate object from the argument Polar coordinate.
Ellipsoidal(Polar polar, Ellipsoid ellipsoid)
          Construct an Ellipsoidal coordinate object that cooresponds to the given Polar coordinate.
 
Method Summary
 boolean equals(java.lang.Object obj)
          Compare two Ellipsoidal coordinate objects for equality.
 Cartesian getCartesian()
          Get the Cartesian representation of the Ellipsoidal coordinate.
 void getCartesian(Cartesian cartesian)
          Get the Cartesian representation of the Ellipsoidal coordinate object.
 Cartesian getCartesian(Length scale)
          Get the Cartesian representation of the Ellipsoidal coordinate object.
 Ellipsoid getEllipsoid()
          Get the Ellipsoid component of this coordinate object.
 int hashCode()
          Calculate the hashcode
 void set(Cartesian cartesian)
          Set the Ellipsoidal coordinate object's components.
 void set(Cartesian cartesian, Ellipsoid ellipsoid)
          Set the Ellipsoidal coordinate object's components.
 void set(double longitudeDegrees, double latitudeDegrees, Length elevation, Ellipsoid ellipsoid)
          Set the Ellipsoidal coordinate object's components.
 void set(Polar polar)
          Set the Ellipsoidal coordinate object's components.
 void set(Polar polar, Ellipsoid ellipsoid)
          Set the Ellipsoidal coordinate object's components.
 void setEllipsoid(Ellipsoid ellipsoid)
          Set the Ellipsoid component of this coordinate object.
 
Methods inherited from class org.jeospace.coordinate.Polar
clear, getAngularSeparation, set, set, setToAntipode, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Ellipsoidal

public Ellipsoidal()
Construct an Ellipsoidal coordinate object with default parameters.
longitude = 0 degrees
latitude = 0 degrees
elevation = 0 meters
ellipsoid = a sphere of 1 km radius


Ellipsoidal

public Ellipsoidal(Ellipsoid ellipsoid)
Construct an Ellipsoidal coordinate object with default coordinate parameters and the specified ellipsoid.
longitude = 0 degrees
latitude = 0 degrees
elevation = 0 meters

Parameters:
ellipsoid - the Ellipsoid that this coordinate object is defined for.

Ellipsoidal

public Ellipsoidal(Polar polar)
Construct an Ellipsoidal coordinate object from the argument Polar coordinate.

Parameters:
polar - the Polar coordinate to represent as an Ellipsoidal coordinate.

Ellipsoidal

public Ellipsoidal(Cartesian cartesian,
                   Ellipsoid ellipsoid)
Construct an Ellipsoidal coordinate object that cooresponds to the given Cartesian coordinate.

Parameters:
cartesian - the Cartesian coordinate to convert to an Ellipsoidal representation.
ellipsoid - the Ellipsoid that this coordinate object is defined for.

Ellipsoidal

public Ellipsoidal(Polar polar,
                   Ellipsoid ellipsoid)
Construct an Ellipsoidal coordinate object that cooresponds to the given Polar coordinate.

Parameters:
polar - the Polar coordinate to convert to an Ellipsoidal representation.
ellipsoid - the Ellipsoid that this coordinate object is defined for.

Ellipsoidal

public Ellipsoidal(double longitudeDegrees,
                   double latitudeDegrees,
                   Length elevation)
Construct an Ellipsoidal coordinate object with the given parameters from the given objects.

Parameters:
longitudeDegrees - the double value initializer for the Longitude component.
latitudeDegrees - the double value initializer for the Latitude component.
elevation - the Length component initializer.

Ellipsoidal

public Ellipsoidal(double longitudeDegrees,
                   double latitudeDegrees,
                   Length elevation,
                   Ellipsoid ellipsoid)
Construct an Ellipsoidal coordinate object with the given parameters from the given objects.

Parameters:
longitudeDegrees - the double value initializer for the Longitude component.
latitudeDegrees - the double value initializer for the Latitude component.
elevation - the Length component initializer.
ellipsoid - the Ellipsoid that this coordinate object is defined for.

Ellipsoidal

public Ellipsoidal(Longitude longitude,
                   Latitude latitude,
                   Length elevation)
Construct an Ellipsoidal coordinate object.

Parameters:
longitude - the Longitude component initializer.
latitude - the Latitude component initializer.
elevation - the Length component initializer.

Ellipsoidal

public Ellipsoidal(Longitude longitude,
                   Latitude latitude,
                   Length elevation,
                   Ellipsoid ellipsoid)
Construct an Ellipsoidal coordinate object.

Parameters:
longitude - the Longitude component initializer.
latitude - the Latitude component initializer.
elevation - the Length component initializer.
ellipsoid - the Ellipsoid that this coordinate object is defined for.
Method Detail

set

public void set(Cartesian cartesian,
                Ellipsoid ellipsoid)
Set the Ellipsoidal coordinate object's components.

Parameters:
cartesian - the Cartesian coordinate to convert to an Ellipsoidal representation.
ellipsoid - the Ellipsoid that this coordinate object is defined for.

set

public void set(Polar polar)
Set the Ellipsoidal coordinate object's components.

Overrides:
set in class Polar
Parameters:
polar - the Polar coordinate to represent as an Ellipsoidal coordinate.

set

public void set(Polar polar,
                Ellipsoid ellipsoid)
Set the Ellipsoidal coordinate object's components.

Parameters:
polar - the Polar coordinate to convert to an Ellipsoidal coordinate with respect to the argument ellipsoid.
ellipsoid - the Ellipsoid that this coordinate object is defined for.

set

public void set(double longitudeDegrees,
                double latitudeDegrees,
                Length elevation,
                Ellipsoid ellipsoid)
Set the Ellipsoidal coordinate object's components.

Parameters:
longitudeDegrees - the double value initializer for the Longitude component
latitudeDegrees - the double value initializer for the Latitude component
elevation - the Length component initializer
ellipsoid - the Ellipsoid that this coordinate object is defined for.

set

public void set(Cartesian cartesian)
Set the Ellipsoidal coordinate object's components.

Specified by:
set in class Polar
Parameters:
cartesian - the Cartesian coordinate to convert to an Ellipsoidal representation.

getCartesian

public Cartesian getCartesian()
Get the Cartesian representation of the Ellipsoidal coordinate.

Specified by:
getCartesian in class Polar
Returns:
the cartesian representation of this ellipsoidal coordinate

getCartesian

public Cartesian getCartesian(Length scale)
Get the Cartesian representation of the Ellipsoidal coordinate object.

Specified by:
getCartesian in class Polar
Parameters:
scale - the Length object scale factor.
Returns:
the cartesian representation of this spherical coordinate

getCartesian

public void getCartesian(Cartesian cartesian)
Get the Cartesian representation of the Ellipsoidal coordinate object.

Specified by:
getCartesian in class Polar
Parameters:
cartesian - the Cartesian object to initialize.

setEllipsoid

public void setEllipsoid(Ellipsoid ellipsoid)
Set the Ellipsoid component of this coordinate object.

Parameters:
ellipsoid - the Ellipsoid to set.

getEllipsoid

public Ellipsoid getEllipsoid()
Get the Ellipsoid component of this coordinate object.

Returns:
the Ellipsoid component of this coordinate object.

hashCode

public int hashCode()
Calculate the hashcode

Returns:
the hashcode

equals

public boolean equals(java.lang.Object obj)
Compare two Ellipsoidal coordinate objects for equality. The result is true if and only if the argument object is not null, is an Ellipsoidal coordinate object and represents an identical position as this Ellipsoidal coordinate object.

Two Ellipsoidal coordinate objects are equal only if it's constituent Longitude, Latitude and Length objects are equal.

Parameters:
obj - the object to compare with
Returns:
true if the Ellipsoidal coordinate objects are the same; false otherwise.

Jeospace API

Copyright © 2006 - jeospace.org