public class MapProjectionFactory extends java.lang.Object implements ProjectionConstants
MapProjectionFactory
class creates instances
of map projections.ALASKA, ALBERS, AZMEQD, EQRECT, EQUIDC, GEO, GNOMON, GOOD, GVNSP, HAMMER, HOM, IMOLL, LAMAZ, LAMCC, MAX_PROJECTIONS, MERCAT, MILLER, MOLL, OBEQA, ORTHO, POLYC, PROJECTION_NAMES, PS, ROBIN, SNSOID, SOM, SPCS, STEREO, TM, USDEF, UTM, VGRINT, WAGIV, WAGVII
Modifier | Constructor and Description |
---|---|
protected |
MapProjectionFactory()
Creates a new map projection factory with no GCTP forcing.
|
Modifier and Type | Method and Description |
---|---|
MapProjection |
create(int system,
int zone,
double[] parameters,
int spheroid,
int[] dimensions,
java.awt.geom.AffineTransform affine)
Creates a new map projection from the specified GCTP-style
projection and data parameters.
|
MapProjection |
create(int system,
int zone,
double[] parameters,
int spheroid,
int[] dimensions,
EarthLocation centerLoc,
double[] pixelDims)
Creates a new map projection from the specified GCTP-style
projection and data parameters.
|
static MapProjectionFactory |
getInstance()
Gets an instance of this factory with no GCTP forcing.
|
protected MapProjectionFactory()
public static MapProjectionFactory getInstance()
MapProjection
because it allows the factory to
possibly return a performance-enhanced pure Java version of
a GCTPStyleProjection
object.public MapProjection create(int system, int zone, double[] parameters, int spheroid, int[] dimensions, EarthLocation centerLoc, double[] pixelDims) throws java.awt.geom.NoninvertibleTransformException
SpheroidConstants
and ProjectionConstants
class
should be consulted for valid parameter constants.system
- the map projection system.zone
- the map projection zone for State Plane and UTM
projections.parameters
- an array of 15 GCTP projection parameters.spheroid
- the spheroid code or -1 for custom spheroid.dimensions
- the dimensions of the data grid as [rows,
columns]
.centerLoc
- the earth location at the map center.pixelDims
- the pixel dimensions in meters at the projection
reference point as [height, width]
.java.awt.geom.NoninvertibleTransformException
- if the map
projection to data coordinate affine transform is not
invertible.java.lang.IllegalArgumentException
- if the projection system
and spheroid are incompatible or projection parameters are inconsistent.public MapProjection create(int system, int zone, double[] parameters, int spheroid, int[] dimensions, java.awt.geom.AffineTransform affine) throws java.awt.geom.NoninvertibleTransformException
SpheroidConstants
and ProjectionConstants
class
should be consulted for valid parameter constants.system
- the map projection system.zone
- the map projection zone for State Plane and UTM
projections.parameters
- an array of 15 GCTP projection parameters.spheroid
- the spheroid code or -1 for custom spheroid.dimensions
- the dimensions of the data grid as [rows,
columns]
.affine
- the affine transform for translating data
[row, column]
to map [x, y]
.java.awt.geom.NoninvertibleTransformException
- if the map
projection to data coordinate affine transform is not
invertible.java.lang.IllegalArgumentException
- if the projection system
and spheroid are incompatible or projection parameters are inconsistent.