|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectmccombe.mapping.CoordinateSystem
public abstract class CoordinateSystem
Abstract base class for coordinate systems in general. Each instance of CoordinateSystem contains a Position and references to the Ellipsoid and Datum from which the coordinates are derived. The position itself is independent of Ellipsoid and Datum.
Field Summary | |
---|---|
protected Position |
locus
The Position of this Coordinate |
protected Datum |
ref
The Datum for this point |
protected Ellipsoid |
sph
The Ellipsoid for this point |
Constructor Summary | |
---|---|
protected |
CoordinateSystem()
Creates a new instance of CoordinateSystem using the default Ellipsoid and Datum |
|
CoordinateSystem(Position pos,
Ellipsoid e,
Datum d)
Create a new instance of CoordinateSystem for a specific Position, Ellipsoid and Datum |
Method Summary | |
---|---|
abstract Datum |
defaultDatum()
Get the defaul Datum for an instance of CoordinateSystem. |
abstract Ellipsoid |
defaultEllipsoid()
The default Ellipsoid used by instances of this CoordinateSystem For example, a CoordinateSystem of type OSGB has the AirySphere as its default Ellipsoid |
Datum |
getDatum()
Get the Datum used by this point |
Ellipsoid |
getEllipsoid()
Get the Ellipsoid used by this point |
java.lang.String |
getName()
Get the name of this CoordinateSystem. |
Position |
getPosition()
Get the Position of this point |
XYZ |
getWGS84()
Get the "absolute" cartesian coordinates for this location. |
protected static double |
parseDouble(java.lang.String s)
|
LatLong |
toLatLong()
Get the Latitude & Longitude for this point. |
java.lang.String |
toLatLongString()
Return a String containing values of Latitude & Longitude.referred to the current Ellipsoid & Datum |
abstract java.lang.String |
toString()
Provide a String representing the position in a correct format for the CoordinateSystem |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected Position locus
protected Ellipsoid sph
protected Datum ref
Constructor Detail |
---|
protected CoordinateSystem()
public CoordinateSystem(Position pos, Ellipsoid e, Datum d)
Create a new instance of CoordinateSystem for a specific Position, Ellipsoid and Datum
pos
- Position of the point in this CoordinateSysteme
- Ellipsoid to be used in this CoordinateSystemd
- Datum for this instance of CopordinateSystemMethod Detail |
---|
public LatLong toLatLong()
public java.lang.String toLatLongString()
public Datum getDatum()
public Ellipsoid getEllipsoid()
public java.lang.String getName()
Get the name of this CoordinateSystem. By default, this method returns the short name of the
class. For example, an instance of mccombe.mapping.IrishGrid
returns the name "IrishGrid".
Implementers of sub-classes of CoordinateSystem are encouraged to override this method if a more descriptive name is needed
public Position getPosition()
public XYZ getWGS84()
public abstract Ellipsoid defaultEllipsoid()
public abstract Datum defaultDatum()
public abstract java.lang.String toString()
toString
in class java.lang.Object
protected static double parseDouble(java.lang.String s) throws java.text.ParseException
java.text.ParseException
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |