com.moximedia.aims.projection
Class ProjectionTransverseMercator

java.lang.Object
  extended bycom.moximedia.aims.projection.ProjectionTransverseMercator
All Implemented Interfaces:
java.lang.Cloneable, MeasureUnitsType, Projection, ProjectionType, java.io.Serializable

public class ProjectionTransverseMercator
extends java.lang.Object
implements Projection, ProjectionType, MeasureUnitsType, java.lang.Cloneable, java.io.Serializable

Convenience class for backwards compatibility.

Author:
Doug Cates - www.moximedia.com
See Also:
Serialized Form

Field Summary
 
Fields inherited from interface com.moximedia.aims.types.ProjectionType
PROJECTION_TYPE_ALBERS_CONIC_EQUAL_AREA, PROJECTION_TYPE_GEOGRAPHIC, PROJECTION_TYPE_LAMBERT_CONFORMAL_CONIC_1SP, PROJECTION_TYPE_LAMBERT_CONFORMAL_CONIC_2SP, PROJECTION_TYPE_LAMBERT_CONFORMAL_CONIC_BELGIUM_2SP, PROJECTION_TYPE_MERCATOR_1SP, PROJECTION_TYPE_MERCATOR_2SP, PROJECTION_TYPE_OBLIQUE_STEREOGRAPHIC, PROJECTION_TYPE_ORTHOGRAPHIC, PROJECTION_TYPE_POLAR_STEREOGRAPHIC, PROJECTION_TYPE_POLAR_STEREOGRAPHIC_SERIES, PROJECTION_TYPE_STEREOGRAPHIC, PROJECTION_TYPE_TRANSVERSE_MERCATOR, PROJECTION_TYPE_UTM, PROJECTION_TYPE_UTM_AUTO, PROJECTION_TYPE_WKT
 
Fields inherited from interface com.moximedia.aims.types.MeasureUnitsType
MEASURE_UNITS_DECIMAL_DEGREES, MEASURE_UNITS_FEET, MEASURE_UNITS_IMPERIAL, MEASURE_UNITS_METERS, MEASURE_UNITS_METRES, MEASURE_UNITS_METRIC, MEASURE_UNITS_UNKNOWN, MEASURE_UNITS_US, MEASURE_UNITS_YARDS
 
Constructor Summary
ProjectionTransverseMercator()
          Creates a new instance
 
Method Summary
 java.lang.Object clone()
          Returns a separate copy of this object.
 boolean equals(Projection anotherProjection)
          Returns an indicator of whether this projection is the same as another.
 java.lang.String getAlias()
          Return the alias of the projection
 java.lang.String getAlias(java.util.Locale locale)
          Return the alias of the projection
 CoordinateSystem getCoordinateSystem()
          Method to compare projections.
 ProjectionTransverseMercator getCopy()
          Returns a separate copy of this object.
 java.lang.String getMapCenterString(AimsPoint geoPoint, double scaleFactor)
          Returns the map center coordinate text in the specified locale.
 java.lang.String getName()
          Return the name of the projection
 java.lang.String getName(java.util.Locale locale)
          Return the name of the projection
 double getProjectionParameter(java.lang.String name)
          Gets the value of the specified projection parameter.
 int getProjectionType()
          Gets the projection type enumeration.
 java.lang.String getReportString(AimsPoint geoPoint, double scaleFactor)
          Returns the report for the standard identify reports.
 java.lang.String getSrs()
          Return the spatial reference system code.
 int getUnits()
          Return the map units of the projection.
 java.lang.String getUnitsString()
          Return the map units of the projection as a string.
 double getZone()
          Return the zone of the projection
 boolean isGeographicCoordinateSystem()
          Returns an indicator of whether this coordinate system is geographic.
 boolean isProjectedCoordinateSystem()
          Returns an indicator of whether this coordinate system is projected (non-geographic).
 boolean isValid()
          Gets an indicator of whether the projection is valid.
 AimsPoint project(AimsPoint point)
          Projects a geographic position into this projection.
 void setAlias(java.lang.String alias)
          Sets the alias for the projection for use in reports.
 void setCentralMeridian(double value)
          Sets a projection parameter
 void setEllipsoid(Ellipsoid ellipsoid)
          Sets the ellipsoid.
 void setEllipsoidFromName(java.lang.String name)
          Sets the ellipsoid using its name.
 void setFalseEasting(double value)
          Sets a projection parameter
 void setFalseNorthing(double value)
          Sets a projection parameter
 void setLatitudeOfOrigin(double value)
          Sets a projection parameter
 void setScaleFactor(double value)
          Sets a projection parameter
 void setUnits(int units)
          Sets the units with an enumeration.
 void setUnits(java.lang.String units)
          Sets the units with a String.
 void setXmlAttribute(java.lang.String tag, java.lang.String name, java.lang.String value)
          Sets one of the attributes of this object using a string value.
 void setZone(double zone)
          Sets the central meridian using a UTM zone number.
 void setZone(int zone)
          Sets the central meridian using a UTM zone number.
 java.lang.String toString()
          Displays the projection as a string.
 java.lang.String toWktString()
          Displays the projection parameters as a well known text string.
 AimsPoint unproject(AimsPoint point)
          Unrojects a projection position into geographic.
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ProjectionTransverseMercator

public ProjectionTransverseMercator()
Creates a new instance

Method Detail

setXmlAttribute

public void setXmlAttribute(java.lang.String tag,
                            java.lang.String name,
                            java.lang.String value)
Sets one of the attributes of this object using a string value. This method should only be called from the SAX event handler.

Specified by:
setXmlAttribute in interface Projection
Parameters:
tag - The AXL element tag containing this attribute (not used).
name - The AXL attribute name.
value - The AXL attribute value.

setAlias

public void setAlias(java.lang.String alias)
Sets the alias for the projection for use in reports.

Parameters:
alias - The alternate name for this projection.

clone

public java.lang.Object clone()
Returns a separate copy of this object.

Specified by:
clone in interface Projection
Returns:
A copy of this object as an Object.

getCopy

public ProjectionTransverseMercator getCopy()
Returns a separate copy of this object.

Returns:
A copy of this object.

getAlias

public java.lang.String getAlias()
Return the alias of the projection

Specified by:
getAlias in interface Projection
Returns:
The alias of the projection.

getAlias

public java.lang.String getAlias(java.util.Locale locale)
Return the alias of the projection

Specified by:
getAlias in interface Projection
Parameters:
locale - The locale to format text and numbers.
Returns:
The alias of the projection.

getMapCenterString

public java.lang.String getMapCenterString(AimsPoint geoPoint,
                                           double scaleFactor)
Returns the map center coordinate text in the specified locale.

Specified by:
getMapCenterString in interface Projection
Parameters:
geoPoint - A geographic point.
scaleFactor - The current map scale factor for use in rounding results.
Returns:
The report string.

getName

public java.lang.String getName()
Return the name of the projection

Specified by:
getName in interface Projection
Returns:
The name of the projection.

getName

public java.lang.String getName(java.util.Locale locale)
Return the name of the projection

Specified by:
getName in interface Projection
Parameters:
locale - The locale to format text and numbers.
Returns:
The name of the projection.

project

public AimsPoint project(AimsPoint point)
Projects a geographic position into this projection. Note that this is a simple transformation without dataum shifts.

Specified by:
project in interface Projection
Parameters:
point - The geographic position.
Returns:
The projected position, or null if there is an error.

getReportString

public java.lang.String getReportString(AimsPoint geoPoint,
                                        double scaleFactor)
Returns the report for the standard identify reports.

Specified by:
getReportString in interface Projection
Parameters:
geoPoint - A geographic point.
scaleFactor - The current map scale factor for use in rounding results.
Returns:
The report string.

getSrs

public java.lang.String getSrs()
Return the spatial reference system code.

Specified by:
getSrs in interface Projection
Returns:
The spatial reference system code.

toString

public java.lang.String toString()
Displays the projection as a string.

Specified by:
toString in interface Projection
Returns:
The projection string.

toWktString

public java.lang.String toWktString()
Displays the projection parameters as a well known text string.

Specified by:
toWktString in interface Projection
Returns:
The projection's well known text.

getUnits

public int getUnits()
Return the map units of the projection.

Specified by:
getUnits in interface Projection
Returns:
The map units of the projection.

getUnitsString

public java.lang.String getUnitsString()
Return the map units of the projection as a string.

Specified by:
getUnitsString in interface Projection
Returns:
The map units of the projection as a string.

unproject

public AimsPoint unproject(AimsPoint point)
Unrojects a projection position into geographic. Note that this is a simple transformation without dataum shifts.

Specified by:
unproject in interface Projection
Parameters:
point - The projected position.
Returns:
The geographic position, or null if there is an error.

isGeographicCoordinateSystem

public boolean isGeographicCoordinateSystem()
Returns an indicator of whether this coordinate system is geographic.

Specified by:
isGeographicCoordinateSystem in interface Projection
Returns:
True if it is geographic and valid, otherwise false.

isProjectedCoordinateSystem

public boolean isProjectedCoordinateSystem()
Returns an indicator of whether this coordinate system is projected (non-geographic).

Specified by:
isProjectedCoordinateSystem in interface Projection
Returns:
True if it is projected and valid, otherwise false.

isValid

public boolean isValid()
Gets an indicator of whether the projection is valid.

Specified by:
isValid in interface Projection
Returns:
True if valid, otherwise false.

getCoordinateSystem

public CoordinateSystem getCoordinateSystem()
Method to compare projections.

Specified by:
getCoordinateSystem in interface Projection
Returns:
The geotools coordinate system backing this projection.

equals

public boolean equals(Projection anotherProjection)
Returns an indicator of whether this projection is the same as another.

Specified by:
equals in interface Projection
Parameters:
anotherProjection - The other projection.
Returns:
True if equal, otherwise false.

setCentralMeridian

public void setCentralMeridian(double value)
Sets a projection parameter

Parameters:
value - The projection parameter.

setLatitudeOfOrigin

public void setLatitudeOfOrigin(double value)
Sets a projection parameter

Parameters:
value - The projection parameter.

setFalseEasting

public void setFalseEasting(double value)
Sets a projection parameter

Parameters:
value - The projection parameter.

setFalseNorthing

public void setFalseNorthing(double value)
Sets a projection parameter

Parameters:
value - The projection parameter.

setEllipsoid

public void setEllipsoid(Ellipsoid ellipsoid)
Sets the ellipsoid.

Parameters:
ellipsoid - The ellipsoid for this projection.

setEllipsoidFromName

public void setEllipsoidFromName(java.lang.String name)
Sets the ellipsoid using its name.

Parameters:
name - The ellipsoid name.

setScaleFactor

public void setScaleFactor(double value)
Sets a projection parameter

Parameters:
value - The projection parameter.

setUnits

public void setUnits(int units)
Sets the units with an enumeration.

Parameters:
units - The units enumerations of type MeasureUnitsType.

setUnits

public void setUnits(java.lang.String units)
Sets the units with a String.

Parameters:
units - The units name, FEET, METERS, or METRES.

getProjectionType

public int getProjectionType()
Gets the projection type enumeration.

Specified by:
getProjectionType in interface Projection
Returns:
The projection type enumeration.

setZone

public void setZone(int zone)
Sets the central meridian using a UTM zone number.

Parameters:
zone - The UTM zone number.

setZone

public void setZone(double zone)
Sets the central meridian using a UTM zone number.

Parameters:
zone - The UTM zone number.

getZone

public double getZone()
Return the zone of the projection

Returns:
The zone of the projection.

getProjectionParameter

public double getProjectionParameter(java.lang.String name)
Gets the value of the specified projection parameter.

Specified by:
getProjectionParameter in interface Projection
Returns:
The value, or Double.NaN if the parameter is not found.


Internet Mapping Framework for ArcIMS Java Object Model API (v5.1.00)
Copyright © 2006 Moxi Media Inc. and Province of British Columbia. All Rights Reserved.