C# Class SharpMap.CoordinateSystems.CoordinateSystemFactory

Builds up complex objects from simpler objects or values.

ICoordinateSystemFactory allows applications to make coordinate systems that cannot be created by a ICoordinateSystemAuthorityFactory. This factory is very flexible, whereas the authority factory is easier to use.

So ICoordinateSystemAuthorityFactorycan 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.

Inheritance: ICoordinateSystemFactory
Exibir arquivo Open project: jumpinjackie/fdotoolbox Class Usage Examples

Public Methods

Method Description
CreateCompoundCoordinateSystem ( string name, ICoordinateSystem head, ICoordinateSystem tail ) : ICompoundCoordinateSystem

Creates a ICompoundCoordinateSystem [NOT IMPLEMENTED].

CreateEllipsoid ( string name, double semiMajorAxis, double semiMinorAxis, ILinearUnit linearUnit ) : IEllipsoid

Creates an Ellipsoid from radius values.

CreateFittedCoordinateSystem ( string name, ICoordinateSystem baseCoordinateSystem, string toBaseWkt, List arAxes ) : IFittedCoordinateSystem

Creates a IFittedCoordinateSystem.

The units of the axes in the fitted coordinate system will be inferred from the units of the base coordinate system. If the affine map performs a rotation, then any mixed axes must have identical units. For example, a (lat_deg,lon_deg,height_feet) system can be rotated in the (lat,lon) plane, since both affected axes are in degrees. But you should not rotate this coordinate system in any other plane.

CreateFlattenedSphere ( string name, double semiMajorAxis, double inverseFlattening, ILinearUnit linearUnit ) : IEllipsoid

Creates an Ellipsoid from an major radius, and inverse flattening.

CreateFromWkt ( string WKT ) : ICoordinateSystem

Creates a spatial reference object given its Well-known text representation. The output object may be either a IGeographicCoordinateSystem or a IProjectedCoordinateSystem.

CreateFromXml ( string xml ) : ICoordinateSystem

Creates a coordinate system object from an XML string.

CreateGeocentricCoordinateSystem ( string name, IHorizontalDatum datum, ILinearUnit linearUnit, IPrimeMeridian primeMeridian ) : IGeocentricCoordinateSystem

Creates a CreateGeocentricCoordinateSystem from a datum, ILinearUnit">linear unit and

CreateGeographicCoordinateSystem ( string name, IAngularUnit angularUnit, IHorizontalDatum datum, IPrimeMeridian primeMeridian, AxisInfo axis0, AxisInfo axis1 ) : IGeographicCoordinateSystem

Creates a GeographicCoordinateSystem, which could be Lat/Lon or Lon/Lat.

CreateHorizontalDatum ( string name, DatumType datumType, IEllipsoid ellipsoid, Wgs84ConversionInfo toWgs84 ) : IHorizontalDatum

Creates HorizontalDatum from ellipsoid and Bursa-World parameters.

Since this method contains a set of Bursa-Wolf parameters, the created datum will always have a relationship to WGS84. If you wish to create a horizontal datum that has no relationship with WGS84, then you can either specify a DatumType">horizontalDatumType of

CreateLocalCoordinateSystem ( string name, ILocalDatum datum, IUnit unit, List axes ) : ILocalCoordinateSystem

Creates a local coordinate system.

The dimension of the local coordinate system is determined by the size of the axis array. All the axes will have the same units. If you want to make a coordinate system with mixed units, then you can make a compound coordinate system from different local coordinate systems.

CreateLocalDatum ( string name, DatumType datumType ) : ILocalDatum

Creates a ILocalDatum.

CreatePrimeMeridian ( string name, IAngularUnit angularUnit, double longitude ) : IPrimeMeridian

Creates a PrimeMeridian, relative to Greenwich.

CreateProjectedCoordinateSystem ( string name, IGeographicCoordinateSystem gcs, IProjection projection, ILinearUnit linearUnit, AxisInfo axis0, AxisInfo axis1 ) : IProjectedCoordinateSystem

Creates a ProjectedCoordinateSystem using a projection object.

CreateProjection ( string name, string wktProjectionClass, List parameters ) : IProjection

Creates a Projection.

CreateVerticalCoordinateSystem ( string name, IVerticalDatum datum, ILinearUnit verticalUnit, AxisInfo axis ) : IVerticalCoordinateSystem

Creates a IVerticalCoordinateSystem from a datum and linear units.

CreateVerticalDatum ( string name, DatumType datumType ) : IVerticalDatum

Creates a IVerticalDatum from an enumerated type value.

Method Details

CreateCompoundCoordinateSystem() public method

Creates a ICompoundCoordinateSystem [NOT IMPLEMENTED].
public CreateCompoundCoordinateSystem ( string name, ICoordinateSystem head, ICoordinateSystem tail ) : ICompoundCoordinateSystem
name string Name of compound coordinate system.
head ICoordinateSystem Head coordinate system
tail ICoordinateSystem Tail coordinate system
return ICompoundCoordinateSystem

CreateEllipsoid() public method

Creates an Ellipsoid from radius values.
public CreateEllipsoid ( string name, double semiMajorAxis, double semiMinorAxis, ILinearUnit linearUnit ) : IEllipsoid
name string Name of ellipsoid
semiMajorAxis double
semiMinorAxis double
linearUnit ILinearUnit
return IEllipsoid

CreateFittedCoordinateSystem() public method

Creates a IFittedCoordinateSystem.
The units of the axes in the fitted coordinate system will be inferred from the units of the base coordinate system. If the affine map performs a rotation, then any mixed axes must have identical units. For example, a (lat_deg,lon_deg,height_feet) system can be rotated in the (lat,lon) plane, since both affected axes are in degrees. But you should not rotate this coordinate system in any other plane.
public CreateFittedCoordinateSystem ( string name, ICoordinateSystem baseCoordinateSystem, string toBaseWkt, List arAxes ) : IFittedCoordinateSystem
name string Name of coordinate system
baseCoordinateSystem ICoordinateSystem Base coordinate system
toBaseWkt string
arAxes List
return IFittedCoordinateSystem

CreateFlattenedSphere() public method

Creates an Ellipsoid from an major radius, and inverse flattening.
public CreateFlattenedSphere ( string name, double semiMajorAxis, double inverseFlattening, ILinearUnit linearUnit ) : IEllipsoid
name string Name of ellipsoid
semiMajorAxis double Semi major-axis
inverseFlattening double Inverse flattening
linearUnit ILinearUnit Linear unit
return IEllipsoid

CreateFromWkt() public method

Creates a spatial reference object given its Well-known text representation. The output object may be either a IGeographicCoordinateSystem or a IProjectedCoordinateSystem.
public CreateFromWkt ( string WKT ) : ICoordinateSystem
WKT string The Well-known text representation for the spatial reference
return ICoordinateSystem

CreateFromXml() public method

Creates a coordinate system object from an XML string.
public CreateFromXml ( string xml ) : ICoordinateSystem
xml string XML representation for the spatial reference
return ICoordinateSystem

CreateGeocentricCoordinateSystem() public method

Creates a CreateGeocentricCoordinateSystem from a datum, ILinearUnit">linear unit and
public CreateGeocentricCoordinateSystem ( string name, IHorizontalDatum datum, ILinearUnit linearUnit, IPrimeMeridian primeMeridian ) : IGeocentricCoordinateSystem
name string Name of geocentric coordinate system
datum IHorizontalDatum Horizontal datum
linearUnit ILinearUnit Linear unit
primeMeridian IPrimeMeridian Prime meridian
return IGeocentricCoordinateSystem

CreateGeographicCoordinateSystem() public method

Creates a GeographicCoordinateSystem, which could be Lat/Lon or Lon/Lat.
public CreateGeographicCoordinateSystem ( string name, IAngularUnit angularUnit, IHorizontalDatum datum, IPrimeMeridian primeMeridian, AxisInfo axis0, AxisInfo axis1 ) : IGeographicCoordinateSystem
name string Name of geographical coordinate system
angularUnit IAngularUnit Angular units
datum IHorizontalDatum Horizontal datum
primeMeridian IPrimeMeridian Prime meridian
axis0 AxisInfo First axis
axis1 AxisInfo Second axis
return IGeographicCoordinateSystem

CreateHorizontalDatum() public method

Creates HorizontalDatum from ellipsoid and Bursa-World parameters.
Since this method contains a set of Bursa-Wolf parameters, the created datum will always have a relationship to WGS84. If you wish to create a horizontal datum that has no relationship with WGS84, then you can either specify a DatumType">horizontalDatumType of
public CreateHorizontalDatum ( string name, DatumType datumType, IEllipsoid ellipsoid, Wgs84ConversionInfo toWgs84 ) : IHorizontalDatum
name string Name of ellipsoid
datumType DatumType Type of datum
ellipsoid IEllipsoid Ellipsoid
toWgs84 Wgs84ConversionInfo Wgs84 conversion parameters
return IHorizontalDatum

CreateLocalCoordinateSystem() public method

Creates a local coordinate system.
The dimension of the local coordinate system is determined by the size of the axis array. All the axes will have the same units. If you want to make a coordinate system with mixed units, then you can make a compound coordinate system from different local coordinate systems.
public CreateLocalCoordinateSystem ( string name, ILocalDatum datum, IUnit unit, List axes ) : ILocalCoordinateSystem
name string Name of local coordinate system
datum ILocalDatum Local datum
unit IUnit Units
axes List Axis info
return ILocalCoordinateSystem

CreateLocalDatum() public method

Creates a ILocalDatum.
public CreateLocalDatum ( string name, DatumType datumType ) : ILocalDatum
name string Name of datum
datumType DatumType Datum type
return ILocalDatum

CreatePrimeMeridian() public method

Creates a PrimeMeridian, relative to Greenwich.
public CreatePrimeMeridian ( string name, IAngularUnit angularUnit, double longitude ) : IPrimeMeridian
name string Name of prime meridian
angularUnit IAngularUnit Angular unit
longitude double Longitude
return IPrimeMeridian

CreateProjectedCoordinateSystem() public method

Creates a ProjectedCoordinateSystem using a projection object.
public CreateProjectedCoordinateSystem ( string name, IGeographicCoordinateSystem gcs, IProjection projection, ILinearUnit linearUnit, AxisInfo axis0, AxisInfo axis1 ) : IProjectedCoordinateSystem
name string Name of projected coordinate system
gcs IGeographicCoordinateSystem Geographic coordinate system
projection IProjection Projection
linearUnit ILinearUnit Linear unit
axis0 AxisInfo Primary axis
axis1 AxisInfo Secondary axis
return IProjectedCoordinateSystem

CreateProjection() public method

Creates a Projection.
public CreateProjection ( string name, string wktProjectionClass, List parameters ) : IProjection
name string Name of projection
wktProjectionClass string Projection class
parameters List Projection parameters
return IProjection

CreateVerticalCoordinateSystem() public method

Creates a IVerticalCoordinateSystem from a datum and linear units.
public CreateVerticalCoordinateSystem ( string name, IVerticalDatum datum, ILinearUnit verticalUnit, AxisInfo axis ) : IVerticalCoordinateSystem
name string Name of vertical coordinate system
datum IVerticalDatum Vertical datum
verticalUnit ILinearUnit Unit
axis AxisInfo Axis info
return IVerticalCoordinateSystem

CreateVerticalDatum() public method

Creates a IVerticalDatum from an enumerated type value.
public CreateVerticalDatum ( string name, DatumType datumType ) : IVerticalDatum
name string Name of datum
datumType DatumType Type of datum
return IVerticalDatum