All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
te::srs::GeographicCoordinateSystem Class Reference

A Geographic Coordinate System (GEOGCS). More...

#include <GeographicCoordinateSystem.h>

Inheritance diagram for te::srs::GeographicCoordinateSystem:
te::srs::SpatialReferenceSystem

Public Member Functions

 GeographicCoordinateSystem (const std::string &name="", const std::string unitName="degree", double primem=0.0)
 Constructor with parameters. More...
 
const DatumgetDatum () const
 Returns the associated Datum. More...
 
const std::string & getName () const
 Returns the SRS name. More...
 
double getPrimem () const
 Returns the meridian used to take longitude measurements from. More...
 
void getSRID (int &id, std::string &authName) const
 Returns SRS integer identification. More...
 
const std::string & getUnitName () const
 Returns the SRS unit name. More...
 
std::string getWKT () const
 Returns an OGC's WKT representation for the SRS. More...
 
bool isGeographic () const
 Returns true is a geographic coordinate system and false otherwise. More...
 
void setDatum (Datum *datum)
 Sets the associated Datum. More...
 
void setName (const std::string &name)
 Sets the SRS name. More...
 
void setPrimem (double primen)
 Sets the meridian used to take longitude measurements from. More...
 
void setSRID (int id, const std::string &authName="EPSG")
 Sets the SRS integer identification. More...
 
void setUnitName (const std::string &name)
 Sets the SRS unit name. More...
 
 ~GeographicCoordinateSystem ()
 Destructor. More...
 

Protected Attributes

std::string m_name
 
std::pair< unsigned int,
std::string > 
m_srid
 
std::string m_unitName
 

Private Attributes

Datumm_datum
 Datum. More...
 
double m_primem
 The meridian used to take longitude measurements from. More...
 

Detailed Description

A Geographic Coordinate System (GEOGCS).

A Geographic Coordinate System is a coordinate system based on latitude and longitude.

Definition at line 51 of file GeographicCoordinateSystem.h.

Constructor & Destructor Documentation

te::srs::GeographicCoordinateSystem::GeographicCoordinateSystem ( const std::string &  name = "",
const std::string  unitName = "degree",
double  primem = 0.0 
)

Constructor with parameters.

Parameters
nameThe geographic coordinate system name.
unitNameThe name of the angular unit for this GEOGCS.
primemThe meridian used to take longitude measurements from.

Definition at line 36 of file GeographicCoordinateSystem.cpp.

te::srs::GeographicCoordinateSystem::~GeographicCoordinateSystem ( )

Destructor.

Definition at line 44 of file GeographicCoordinateSystem.cpp.

Member Function Documentation

const te::srs::Datum * te::srs::GeographicCoordinateSystem::getDatum ( ) const

Returns the associated Datum.

Returns
A pointer to the GEOGCS datum. Class maintains the pointer ownership.

Definition at line 57 of file GeographicCoordinateSystem.cpp.

const std::string & te::srs::SpatialReferenceSystem::getName ( ) const
inherited

Returns the SRS name.

Definition at line 43 of file SpatialReferenceSystem.cpp.

double te::srs::GeographicCoordinateSystem::getPrimem ( ) const

Returns the meridian used to take longitude measurements from.

Definition at line 62 of file GeographicCoordinateSystem.cpp.

void te::srs::SpatialReferenceSystem::getSRID ( int &  id,
std::string &  authName 
) const
inherited

Returns SRS integer identification.

Parameters
idTo return the unique id (output);
authNameTo return the authority responsible for the id (output).

Definition at line 58 of file SpatialReferenceSystem.cpp.

const std::string & te::srs::SpatialReferenceSystem::getUnitName ( ) const
inherited

Returns the SRS unit name.

Definition at line 53 of file SpatialReferenceSystem.cpp.

std::string te::srs::GeographicCoordinateSystem::getWKT ( ) const
virtual

Returns an OGC's WKT representation for the SRS.

The WKT definition based on document "OpenGIS Implementation Specification: Coordinate Transformation Services Revision 1.00 - pages 18 and 19.

Implements te::srs::SpatialReferenceSystem.

Definition at line 72 of file GeographicCoordinateSystem.cpp.

References te::common::UnitsOfMeasureManager::find(), and te::common::Singleton< UnitsOfMeasureManager >::getInstance().

bool te::srs::GeographicCoordinateSystem::isGeographic ( ) const
virtual

Returns true is a geographic coordinate system and false otherwise.

Implements te::srs::SpatialReferenceSystem.

Definition at line 115 of file GeographicCoordinateSystem.cpp.

void te::srs::GeographicCoordinateSystem::setDatum ( Datum datum)

Sets the associated Datum.

Parameters
datumPointer to GEOGCS datum. Do not pass null. Class takes the pointer ownership.

Definition at line 49 of file GeographicCoordinateSystem.cpp.

void te::srs::SpatialReferenceSystem::setName ( const std::string &  name)
inherited

Sets the SRS name.

Parameters
namethe SRS name.

Definition at line 38 of file SpatialReferenceSystem.cpp.

void te::srs::GeographicCoordinateSystem::setPrimem ( double  primen)

Sets the meridian used to take longitude measurements from.

Parameters
primenThe meridian used to take longitude measurements from.

Definition at line 67 of file GeographicCoordinateSystem.cpp.

void te::srs::SpatialReferenceSystem::setSRID ( int  id,
const std::string &  authName = "EPSG" 
)
inherited

Sets the SRS integer identification.

Spatial reference systems can be referred to using a SRID integer, given by an authority, such as the EPSG codes defined by the International Association of Oil and Gas Producers.

Parameters
idThe SRS integer identifier.
authNameThe authority responsible for the identifier. Default "EPSG".

Definition at line 64 of file SpatialReferenceSystem.cpp.

void te::srs::SpatialReferenceSystem::setUnitName ( const std::string &  name)
inherited

Sets the SRS unit name.

Parameters
namethe SRS unit name.

Definition at line 48 of file SpatialReferenceSystem.cpp.

Member Data Documentation

Datum* te::srs::GeographicCoordinateSystem::m_datum
private

Datum.

Definition at line 93 of file GeographicCoordinateSystem.h.

std::string te::srs::SpatialReferenceSystem::m_name
protectedinherited

Definition at line 112 of file SpatialReferenceSystem.h.

double te::srs::GeographicCoordinateSystem::m_primem
private

The meridian used to take longitude measurements from.

Definition at line 94 of file GeographicCoordinateSystem.h.

std::pair<unsigned int,std::string> te::srs::SpatialReferenceSystem::m_srid
protectedinherited

Definition at line 115 of file SpatialReferenceSystem.h.

std::string te::srs::SpatialReferenceSystem::m_unitName
protectedinherited

Definition at line 113 of file SpatialReferenceSystem.h.


The documentation for this class was generated from the following files: