|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.geotools.cs.CoordinateSystemFactory
CRSFactory
.
Builds up complex objects from simpler objects or values.
CoordinateSystemFactory
allows applications to make coordinate
systems that cannot be created by a CoordinateSystemAuthorityFactory
.
This factory is very flexible, whereas the authority factory is easier to
use.
So CoordinateSystemAuthorityFactory
can be used to make 'standard'
coordinate systems, and CoordinateSystemFactory
can be used to
make "special" coordinate systems.
For example, the EPSG authority has codes for USA state plane coordinate
systems using the NAD83 datum, but these coordinate systems always use
meters. EPSG does not have codes for NAD83 state plane coordinate systems
that use feet units. This factory lets an application create such a hybrid
coordinate system.
CS_CoordinateSystemFactory
Constructor Summary | |
protected |
CoordinateSystemFactory()
Deprecated. Default constructor. |
Method Summary | |
CompoundCoordinateSystem |
createCompoundCoordinateSystem(java.lang.CharSequence name,
CoordinateSystem head,
CoordinateSystem tail)
Deprecated. Creates a compound coordinate system. |
Ellipsoid |
createEllipsoid(java.lang.CharSequence name,
double semiMajorAxis,
double semiMinorAxis,
Unit unit)
Deprecated. Creates an ellipsoid from radius values. |
FittedCoordinateSystem |
createFittedCoordinateSystem(java.lang.CharSequence name,
CoordinateSystem base,
MathTransform toBase,
AxisInfo[] axes)
Deprecated. Creates a fitted coordinate system. |
Ellipsoid |
createFlattenedSphere(java.lang.CharSequence name,
double semiMajorAxis,
double inverseFlattening,
Unit unit)
Deprecated. Creates an ellipsoid from an major radius, and inverse flattening. |
CoordinateSystem |
createFromWKT(java.lang.String text)
Deprecated. Creates a coordinate system object from a Well-Known Text (WKT) string. |
GeocentricCoordinateSystem |
createGeocentricCoordinateSystem(java.lang.CharSequence name,
Unit unit,
HorizontalDatum datum,
PrimeMeridian meridian,
AxisInfo[] axis)
Deprecated. Constructs a geocentric coordinate system. |
GeographicCoordinateSystem |
createGeographicCoordinateSystem(java.lang.CharSequence name,
HorizontalDatum datum)
Deprecated. Creates a geographic coordinate system. |
GeographicCoordinateSystem |
createGeographicCoordinateSystem(java.lang.CharSequence name,
Unit unit,
HorizontalDatum datum,
PrimeMeridian meridian,
AxisInfo axis0,
AxisInfo axis1)
Deprecated. Creates a geographic coordinate system, which could be latitude/longiude or longitude/latitude. |
HorizontalDatum |
createHorizontalDatum(java.lang.CharSequence name,
DatumType.Horizontal type,
Ellipsoid ellipsoid,
WGS84ConversionInfo toWGS84)
Deprecated. Creates horizontal datum from ellipsoid and Bursa-Wolf parameters. |
HorizontalDatum |
createHorizontalDatum(java.lang.CharSequence name,
Ellipsoid ellipsoid)
Deprecated. Creates horizontal datum from an ellipsoid. |
LocalCoordinateSystem |
createLocalCoordinateSystem(java.lang.CharSequence name,
LocalDatum datum,
Unit[] units,
AxisInfo[] axes)
Deprecated. Creates a local coordinate system. |
LocalCoordinateSystem |
createLocalCoordinateSystem(java.lang.CharSequence name,
LocalDatum datum,
Unit unit,
AxisInfo[] axes)
Deprecated. Creates a local coordinate system. |
LocalDatum |
createLocalDatum(java.lang.CharSequence name,
DatumType.Local type)
Deprecated. Creates a local datum. |
PrimeMeridian |
createPrimeMeridian(java.lang.CharSequence name,
Unit unit,
double longitude)
Deprecated. Creates a prime meridian, relative to Greenwich. |
ProjectedCoordinateSystem |
createProjectedCoordinateSystem(java.lang.CharSequence name,
GeographicCoordinateSystem gcs,
Projection projection)
Deprecated. Creates a projected coordinate system using the specified geographic system. |
ProjectedCoordinateSystem |
createProjectedCoordinateSystem(java.lang.CharSequence name,
GeographicCoordinateSystem gcs,
Projection projection,
Unit unit,
AxisInfo axis0,
AxisInfo axis1)
Deprecated. Creates a projected coordinate system using a projection object. |
Projection |
createProjection(java.lang.CharSequence name,
java.lang.String classification,
Ellipsoid ellipsoid,
java.awt.geom.Point2D centre,
java.awt.geom.Point2D translation)
Deprecated. Convenience method for constructing a projection using the specified ellipsoid. |
Projection |
createProjection(java.lang.CharSequence name,
java.lang.String classification,
javax.media.jai.ParameterList parameters)
Deprecated. Creates a projection. |
javax.media.jai.ParameterList |
createProjectionParameterList(java.lang.String classification)
Deprecated. Returns a default parameter list for the specified projection. |
VerticalCoordinateSystem |
createVerticalCoordinateSystem(java.lang.CharSequence name,
VerticalDatum datum)
Deprecated. Creates a vertical coordinate system from a datum. |
VerticalCoordinateSystem |
createVerticalCoordinateSystem(java.lang.CharSequence name,
VerticalDatum datum,
Unit unit,
AxisInfo axis)
Deprecated. Creates a vertical coordinate system from a datum and linear units. |
VerticalDatum |
createVerticalDatum(java.lang.CharSequence name,
DatumType.Vertical type)
Deprecated. Creates a vertical datum from an enumerated type value. |
static CoordinateSystemFactory |
getDefault()
Deprecated. Returns the default coordinate system factory. |
java.text.Format |
getWKTFormat(java.util.Locale locale)
Deprecated. Returns an object to use for parsing and formatting Well-Known Text. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
protected CoordinateSystemFactory()
Method Detail |
public static CoordinateSystemFactory getDefault()
public GeocentricCoordinateSystem createGeocentricCoordinateSystem(java.lang.CharSequence name, Unit unit, HorizontalDatum datum, PrimeMeridian meridian, AxisInfo[] axis) throws org.opengis.referencing.FactoryException
name
- The coordinate system name.unit
- The linear unit.datum
- The horizontal datum.meridian
- The prime meridian.axis
- The axis info. This is usually an array of length 3.
java.lang.IllegalArgumentException
- if an argument is null
or incompatible with the object to be created.
org.opengis.referencing.FactoryException
- if an error occurred during the object creation.
It may be, for example, a network error or a failure on the
server side.public GeographicCoordinateSystem createGeographicCoordinateSystem(java.lang.CharSequence name, HorizontalDatum datum) throws org.opengis.referencing.FactoryException
name
- Name to give new object.datum
- Horizontal datum for created coordinate system.
java.lang.IllegalArgumentException
- if an argument is null
or incompatible with the object to be created.
org.opengis.referencing.FactoryException
- if an error occurred during the object creation.
It may be, for example, a network error or a failure on the
server side.public GeographicCoordinateSystem createGeographicCoordinateSystem(java.lang.CharSequence name, Unit unit, HorizontalDatum datum, PrimeMeridian meridian, AxisInfo axis0, AxisInfo axis1) throws org.opengis.referencing.FactoryException
name
- Name to give new object.unit
- Angular units for created coordinate system.datum
- Horizontal datum for created coordinate system.meridian
- Prime Meridian for created coordinate system.axis0
- Details of 0th ordinates.axis1
- Details of 1st ordinates.
java.lang.IllegalArgumentException
- if an argument is null
or incompatible with the object to be created.
org.opengis.referencing.FactoryException
- if an error occurred during the object creation.
It may be, for example, a network error or a failure on the
server side.CS_CoordinateSystemFactory.createGeographicCoordinateSystem(java.lang.String, org.opengis.cs.CS_AngularUnit, org.opengis.cs.CS_HorizontalDatum, org.opengis.cs.CS_PrimeMeridian, org.opengis.cs.CS_AxisInfo, org.opengis.cs.CS_AxisInfo)
public ProjectedCoordinateSystem createProjectedCoordinateSystem(java.lang.CharSequence name, GeographicCoordinateSystem gcs, Projection projection) throws org.opengis.referencing.FactoryException
name
- Name to give new object.gcs
- Geographic coordinate system to base projection on.projection
- Projection from geographic to projected coordinate system.
java.lang.IllegalArgumentException
- if an argument is null
or incompatible with the object to be created.
org.opengis.referencing.FactoryException
- if an error occurred during the object creation.
It may be, for example, a network error or a failure on the
server side.public ProjectedCoordinateSystem createProjectedCoordinateSystem(java.lang.CharSequence name, GeographicCoordinateSystem gcs, Projection projection, Unit unit, AxisInfo axis0, AxisInfo axis1) throws org.opengis.referencing.FactoryException
name
- Name to give new object.gcs
- Geographic coordinate system to base projection on.projection
- Projection from geographic to projected coordinate system.unit
- Linear units of returned PCS.axis0
- Details of 0th ordinates in returned PCS coordinates.axis1
- Details of 1st ordinates in returned PCS coordinates.
java.lang.IllegalArgumentException
- if an argument is null
or incompatible with the object to be created.
org.opengis.referencing.FactoryException
- if an error occurred during the object creation.
It may be, for example, a network error or a failure on the
server side.CS_CoordinateSystemFactory.createProjectedCoordinateSystem(java.lang.String, org.opengis.cs.CS_GeographicCoordinateSystem, org.opengis.cs.CS_Projection, org.opengis.cs.CS_LinearUnit, org.opengis.cs.CS_AxisInfo, org.opengis.cs.CS_AxisInfo)
public VerticalCoordinateSystem createVerticalCoordinateSystem(java.lang.CharSequence name, VerticalDatum datum) throws org.opengis.referencing.FactoryException
name
- Name to give new object.datum
- Datum to use for new coordinate system.
java.lang.IllegalArgumentException
- if an argument is null
or incompatible with the object to be created.
org.opengis.referencing.FactoryException
- if an error occurred during the object creation.
It may be, for example, a network error or a failure on the
server side.public VerticalCoordinateSystem createVerticalCoordinateSystem(java.lang.CharSequence name, VerticalDatum datum, Unit unit, AxisInfo axis) throws org.opengis.referencing.FactoryException
name
- Name to give new object.datum
- Datum to use for new coordinate system.unit
- Units to use for new coordinate system.axis
- Axis to use for new coordinate system.
java.lang.IllegalArgumentException
- if an argument is null
or incompatible with the object to be created.
org.opengis.referencing.FactoryException
- if an error occurred during the object creation.
It may be, for example, a network error or a failure on the
server side.CS_CoordinateSystemFactory.createVerticalCoordinateSystem(java.lang.String, org.opengis.cs.CS_VerticalDatum, org.opengis.cs.CS_LinearUnit, org.opengis.cs.CS_AxisInfo)
public CompoundCoordinateSystem createCompoundCoordinateSystem(java.lang.CharSequence name, CoordinateSystem head, CoordinateSystem tail) throws org.opengis.referencing.FactoryException
name
- Name to give new object.head
- Coordinate system to use for earlier ordinates.tail
- Coordinate system to use for later ordinates.
java.lang.IllegalArgumentException
- if an argument is null
or incompatible with the object to be created.
org.opengis.referencing.FactoryException
- if an error occurred during the object creation.
It may be, for example, a network error or a failure on the
server side.CS_CoordinateSystemFactory.createCompoundCoordinateSystem(java.lang.String, org.opengis.cs.CS_CoordinateSystem, org.opengis.cs.CS_CoordinateSystem)
public FittedCoordinateSystem createFittedCoordinateSystem(java.lang.CharSequence name, CoordinateSystem base, MathTransform toBase, AxisInfo[] axes) throws org.opengis.referencing.FactoryException
name
- Name to give new object.base
- Coordinate system to base the fitted CS on.toBase
- The transform from created CS to base CS.axes
- Axes for fitted coordinate system. The number of axes must match
the source dimension of the transform toBase
. If this
argument is null
, then axes will be infered from the
base coordinate system.
java.lang.IllegalArgumentException
- if an argument is null
or incompatible with the object to be created.
org.opengis.referencing.FactoryException
CS_CoordinateSystemFactory.createFittedCoordinateSystem(java.lang.String, org.opengis.cs.CS_CoordinateSystem, java.lang.String, org.opengis.cs.CS_AxisInfo[])
public LocalCoordinateSystem createLocalCoordinateSystem(java.lang.CharSequence name, LocalDatum datum, Unit unit, AxisInfo[] axes) throws org.opengis.referencing.FactoryException
name
- Name to give new object.datum
- Local datum to use in created CS.unit
- Units to use for all axes in created CS.axes
- Axes to use in created CS.
java.lang.IllegalArgumentException
- if an argument is null
or incompatible with the object to be created.
org.opengis.referencing.FactoryException
- if an error occurred during the object creation.
It may be, for example, a network error or a failure on the
server side.CS_CoordinateSystemFactory.createLocalCoordinateSystem(java.lang.String, org.opengis.cs.CS_LocalDatum, org.opengis.cs.CS_Unit, org.opengis.cs.CS_AxisInfo[])
public LocalCoordinateSystem createLocalCoordinateSystem(java.lang.CharSequence name, LocalDatum datum, Unit[] units, AxisInfo[] axes) throws org.opengis.referencing.FactoryException
name
- Name to give new object.datum
- Local datum to use in created coordinate system.units
- Units to use in created coordinate system.axes
- Axes to use in created coordinate system.
java.lang.IllegalArgumentException
- if an argument is null
or incompatible with the object to be created.
org.opengis.referencing.FactoryException
- if an error occurred during the object creation.
It may be, for example, a network error or a failure on the
server side.public Ellipsoid createEllipsoid(java.lang.CharSequence name, double semiMajorAxis, double semiMinorAxis, Unit unit) throws org.opengis.referencing.FactoryException
name
- Name to give new object.semiMajorAxis
- Equatorial radius in supplied linear units.semiMinorAxis
- Polar radius in supplied linear units.unit
- Linear units of ellipsoid axes.
java.lang.IllegalArgumentException
- if an argument is null
or incompatible with the object to be created.
org.opengis.referencing.FactoryException
- if an error occurred during the object creation.
It may be, for example, a network error or a failure on the
server side.CS_CoordinateSystemFactory.createEllipsoid(java.lang.String, double, double, org.opengis.cs.CS_LinearUnit)
public Ellipsoid createFlattenedSphere(java.lang.CharSequence name, double semiMajorAxis, double inverseFlattening, Unit unit) throws org.opengis.referencing.FactoryException
name
- Name to give new object.semiMajorAxis
- Equatorial radius in supplied linear units.inverseFlattening
- Eccentricity of ellipsoid.unit
- Linear units of major axis.
java.lang.IllegalArgumentException
- if an argument is null
or incompatible with the object to be created.
org.opengis.referencing.FactoryException
- if an error occurred during the object creation.
It may be, for example, a network error or a failure on the
server side.CS_CoordinateSystemFactory.createFlattenedSphere(java.lang.String, double, double, org.opengis.cs.CS_LinearUnit)
public PrimeMeridian createPrimeMeridian(java.lang.CharSequence name, Unit unit, double longitude) throws org.opengis.referencing.FactoryException
name
- Name to give new object.unit
- Angular units of longitude.longitude
- Longitude of prime meridian in supplied angular units
East of Greenwich.
java.lang.IllegalArgumentException
- if an argument is null
or incompatible with the object to be created.
org.opengis.referencing.FactoryException
- if an error occurred during the object creation.
It may be, for example, a network error or a failure on the
server side.CS_CoordinateSystemFactory.createPrimeMeridian(java.lang.String, org.opengis.cs.CS_AngularUnit, double)
public Projection createProjection(java.lang.CharSequence name, java.lang.String classification, javax.media.jai.ParameterList parameters) throws org.opengis.referencing.FactoryException
"semi_major"
and "semi_minor"
parameters.
The set of legal parameters and their default values can be queried
using createProjectionParameterList(java.lang.String)
. Example:
ParameterList
param =createProjectionParameterList
("Transverse_Mercator") .setParameter("semi_major", 6378206.4) .setParameter("semi_minor", 6356583.8);Projection
proj = createProjection("My projection", "Transverse_Mercator", param);
name
- Name to give new object.classification
- Classification string for projection (e.g. "Transverse_Mercator").parameters
- Parameters to use for projection. A default set of parameters can
be constructed using createProjectionParameterList
(classification)
and initialized
using a chain of setParameter(...)
calls.
If null
, then the default parameters will be used.
java.lang.IllegalArgumentException
- if an argument is null
or incompatible with the object to be created.
org.opengis.referencing.FactoryException
- if an error occurred during the object creation.
It may be, for example, a network error or a failure on the
server side.CS_CoordinateSystemFactory.createProjection(java.lang.String, java.lang.String, org.opengis.cs.CS_ProjectionParameter[])
public Projection createProjection(java.lang.CharSequence name, java.lang.String classification, Ellipsoid ellipsoid, java.awt.geom.Point2D centre, java.awt.geom.Point2D translation) throws org.opengis.referencing.FactoryException
name
- Name to give new object.classification
- Classification string for projection (e.g. "Transverse_Mercator").ellipsoid
- Ellipsoid parameter. If non-null, then "semi_major"
and "semi_minor"
parameters will be set accordingly.centre
- Central meridian and latitude of origin, in degrees. If non-null, then
"central_meridian"
and "latitude_of_origin"
will be set accordingly.translation
- False easting and northing, in metres. If non-null, then
"false_easting"
and "false_northing"
will be set accordingly.
java.lang.IllegalArgumentException
- if an argument is null
or incompatible with the object to be created.
org.opengis.referencing.FactoryException
- if an error occurred during the object creation.
It may be, for example, a network error or a failure on the
server side.public javax.media.jai.ParameterList createProjectionParameterList(java.lang.String classification)
classification
- Classification string for projection (e.g. "Transverse_Mercator").
createProjection(CharSequence, String, ParameterList)
public HorizontalDatum createHorizontalDatum(java.lang.CharSequence name, DatumType.Horizontal type, Ellipsoid ellipsoid, WGS84ConversionInfo toWGS84) throws org.opengis.referencing.FactoryException
DatumType.Horizontal.OTHER
as the
horizontalDatumType, or create it via WKT.
name
- Name to give new object.type
- Type of horizontal datum to create.ellipsoid
- Ellipsoid to use in new horizontal datum.toWGS84
- Suggested approximate conversion from new datum to WGS84.
java.lang.IllegalArgumentException
- if an argument is null
or incompatible with the object to be created.
org.opengis.referencing.FactoryException
- if an error occurred during the object creation.
It may be, for example, a network error or a failure on the
server side.CS_CoordinateSystemFactory.createHorizontalDatum(java.lang.String, org.opengis.cs.CS_DatumType, org.opengis.cs.CS_Ellipsoid, org.opengis.cs.CS_WGS84ConversionInfo)
public HorizontalDatum createHorizontalDatum(java.lang.CharSequence name, Ellipsoid ellipsoid) throws org.opengis.referencing.FactoryException
DatumType.Horizontal.OTHER
.
name
- Name to give new object.ellipsoid
- Ellipsoid to use in new horizontal datum.
java.lang.IllegalArgumentException
- if an argument is null
or incompatible with the object to be created.
org.opengis.referencing.FactoryException
- if an error occurred during the object creation.
It may be, for example, a network error or a failure on the
server side.public VerticalDatum createVerticalDatum(java.lang.CharSequence name, DatumType.Vertical type) throws org.opengis.referencing.FactoryException
name
- Name to give new object.type
- Type of vertical datum to create.
java.lang.IllegalArgumentException
- if an argument is null
or incompatible with the object to be created.
org.opengis.referencing.FactoryException
- if an error occurred during the object creation.
It may be, for example, a network error or a failure on the
server side.CS_CoordinateSystemFactory.createVerticalDatum(java.lang.String, org.opengis.cs.CS_DatumType)
public LocalDatum createLocalDatum(java.lang.CharSequence name, DatumType.Local type) throws org.opengis.referencing.FactoryException
name
- Name to give new object.type
- Type of local datum to create.
java.lang.IllegalArgumentException
- if an argument is null
or incompatible with the object to be created.
org.opengis.referencing.FactoryException
- if an error occurred during the object creation.
It may be, for example, a network error or a failure on the
server side.CS_CoordinateSystemFactory.createLocalDatum(java.lang.String, org.opengis.cs.CS_DatumType)
public CoordinateSystem createFromWKT(java.lang.String text) throws org.opengis.referencing.FactoryException
GEOCCS["Geocentric", DATUM["WGS_1984", SPHEROID["WGS 84", 6378137, 298.257223563, AUTHORITY["EPSG","7030"]], TOWGS84[0,0,0,0,0,0,0], AUTHORITY["EPSG","6326"]], PRIMEM["Greenwich",0], UNIT["Meter",1], AXIS["X", OTHER], AXIS["Y", EAST], AXIS["Z", NORTH]]
text
- The Well-Known Text.
null
).
org.opengis.referencing.FactoryException
- if the Well-Known Text can't be parsed,
or if the coordinate system creation failed from some other reason.public java.text.Format getWKTFormat(java.util.Locale locale)
Format.parseObject(String)
method can be used for parsing coordinate
systems, datum, ellipsoid and prime meridian.
locale
- The locale for the parser (usually Locale.US
. This locale
will affect the way numbers are parsed.
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |