Class PolyconicProjection
- java.lang.Object
-
- ucar.unidata.geoloc.ProjectionImpl
-
- ucar.unidata.geoloc.projection.proj4.PolyconicProjection
-
- All Implemented Interfaces:
Serializable
,Projection
public class PolyconicProjection extends ProjectionImpl
Polyconic Projection. This file was semi-automatically converted from the public-domain USGS PROJ source. Bernhard Jenny, 19 September 2010: fixed spherical inverse.- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from class ucar.unidata.geoloc.ProjectionImpl
atts, defaultMapArea, defaultUnits, EARTH_RADIUS, INDEX_LAT, INDEX_LON, INDEX_X, INDEX_Y, isLatLon, name, PI, PI_OVER_2, PI_OVER_4, TOLERANCE
-
-
Constructor Summary
Constructors Constructor Description PolyconicProjection()
PolyconicProjection(double lat0, double lon0)
PolyconicProjection(double lat0, double lon0, double falseEasting, double falseNorthing, Earth ellipsoid)
PolyconicProjection(double lat0, double lon0, Earth ellipsoid)
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description ProjectionImpl
constructCopy()
copy constructor - avoid clone !!boolean
crossSeam(ProjectionPoint pt1, ProjectionPoint pt2)
This returns true when the line between pt1 and pt2 crosses the seam.boolean
equals(Object o)
Returns true if this represents the same Projection as proj.Earth
getEarth()
double
getFalseEasting()
Get the false easting, in km.double
getFalseNorthing()
Get the false northing, in km.double
getOriginLatitude()
Get the origin longitude.double
getOriginLongitude()
Get the origin longitude.String
getProjectionTypeLabel()
Get the label to be used in the gui for this type of projectionint
hashCode()
ProjectionPoint
latLonToProj(LatLonPoint latlon, ProjectionPointImpl result)
Convert a LatLonPoint to projection coordinatesString
paramsToString()
Create a String of the parameters.LatLonPoint
projToLatLon(ProjectionPoint world, LatLonPointImpl result)
Convert projection coordinates to a LatLonPoint Note: a new object is not created on each call for the return value.void
setFalseEasting(double falseEasting)
Deprecated.void
setFalseNorthing(double falseNorthing)
Deprecated.void
setOriginLatitude(double lat)
Deprecated.void
setOriginLongitude(double lon)
Deprecated.-
Methods inherited from class ucar.unidata.geoloc.ProjectionImpl
addParameter, addParameter, addParameter, findProjectionParameter, getClassName, getDefaultMapArea, getDefaultMapAreaLL, getDefaultUnits, getHeader, getName, getProjectionParameters, isLatLon, latLonToProj, latLonToProj, latLonToProj, latLonToProj, latLonToProj, latLonToProj, latLonToProj, latLonToProj, latLonToProj, latLonToProjBB, projToLatLon, projToLatLon, projToLatLon, projToLatLon, projToLatLon, projToLatLonBB, projToLatLonBBold, setDefaultMapArea, setName, toString
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface ucar.unidata.geoloc.Projection
latLonToProj, projToLatLon
-
-
-
-
Constructor Detail
-
PolyconicProjection
public PolyconicProjection()
-
PolyconicProjection
public PolyconicProjection(double lat0, double lon0)
-
PolyconicProjection
public PolyconicProjection(double lat0, double lon0, Earth ellipsoid)
-
PolyconicProjection
public PolyconicProjection(double lat0, double lon0, double falseEasting, double falseNorthing, Earth ellipsoid)
-
-
Method Detail
-
equals
public boolean equals(Object o)
Description copied from class:ProjectionImpl
Returns true if this represents the same Projection as proj.- Specified by:
equals
in interfaceProjection
- Specified by:
equals
in classProjectionImpl
- Parameters:
o
- projection in question- Returns:
- true if this represents the same Projection as proj.
-
getEarth
public Earth getEarth()
-
setOriginLatitude
@Deprecated public void setOriginLatitude(double lat)
Deprecated.Set the origin latitude.- Parameters:
lat
- the origin latitude.
-
getOriginLatitude
public double getOriginLatitude()
Get the origin longitude.- Returns:
- the origin longitude in degrees
-
setOriginLongitude
@Deprecated public void setOriginLongitude(double lon)
Deprecated.Set the origin longitude.- Parameters:
lon
- the origin longitude.
-
getOriginLongitude
public double getOriginLongitude()
Get the origin longitude.- Returns:
- the origin longitude in degrees
-
getFalseEasting
public double getFalseEasting()
Get the false easting, in km.- Returns:
- the false easting in km
-
setFalseEasting
@Deprecated public void setFalseEasting(double falseEasting)
Deprecated.Set the false_easting, in km. natural_x_coordinate + false_easting = x coordinate- Parameters:
falseEasting
- x offset
-
getFalseNorthing
public double getFalseNorthing()
Get the false northing, in km.- Returns:
- the false northing in km
-
setFalseNorthing
@Deprecated public void setFalseNorthing(double falseNorthing)
Deprecated.Set the false northing, in km. natural_y_coordinate + false_northing = y coordinate- Parameters:
falseNorthing
- y offset
-
getProjectionTypeLabel
public String getProjectionTypeLabel()
Get the label to be used in the gui for this type of projection- Overrides:
getProjectionTypeLabel
in classProjectionImpl
- Returns:
- Type label
-
paramsToString
public String paramsToString()
Create a String of the parameters.- Specified by:
paramsToString
in interfaceProjection
- Specified by:
paramsToString
in classProjectionImpl
- Returns:
- a String of the parameters
-
crossSeam
public boolean crossSeam(ProjectionPoint pt1, ProjectionPoint pt2)
This returns true when the line between pt1 and pt2 crosses the seam. When the cone is flattened, the "seam" is lon0 +- 180.- Specified by:
crossSeam
in interfaceProjection
- Specified by:
crossSeam
in classProjectionImpl
- Parameters:
pt1
- point 1pt2
- point 2- Returns:
- true when the line between pt1 and pt2 crosses the seam.
-
latLonToProj
public ProjectionPoint latLonToProj(LatLonPoint latlon, ProjectionPointImpl result)
Convert a LatLonPoint to projection coordinates- Specified by:
latLonToProj
in interfaceProjection
- Specified by:
latLonToProj
in classProjectionImpl
- Parameters:
latlon
- convert from these lat, lon coordinatesresult
- the object to write to- Returns:
- the given result
-
projToLatLon
public LatLonPoint projToLatLon(ProjectionPoint world, LatLonPointImpl result)
Convert projection coordinates to a LatLonPoint Note: a new object is not created on each call for the return value.- Specified by:
projToLatLon
in interfaceProjection
- Specified by:
projToLatLon
in classProjectionImpl
- Parameters:
world
- convert from these projection coordinatesresult
- the object to write to- Returns:
- LatLonPoint convert to these lat/lon coordinates
-
constructCopy
public ProjectionImpl constructCopy()
Description copied from class:ProjectionImpl
copy constructor - avoid clone !!- Specified by:
constructCopy
in classProjectionImpl
- Returns:
- a copy of this Projection. TODO return Projection in ver6
-
-