1 #ifndef _utl_UTMPoint_h_
2 #define _utl_UTMPoint_h_
4 #include <utl/CoordinateSystem.h>
5 #include <utl/ReferenceEllipsoid.h>
7 #include <boost/tuple/tuple.hpp>
62 UTMPoint(
const double theNorthing,
const double theEasting,
63 const double theHeight,
64 const int theZone,
const char theBand,
90 UTMPoint(
const double theNorthing,
const double theEasting,
91 const double theHeight,
92 const int theZone,
const char theBand,
158 const double theLongitude,
159 const double theHeight,
176 const double theLongitude,
177 const double theHeight,
269 const double theLongitude);
275 const double theLongitude);
295 virtual std::string GetExceptionName()
const
296 {
return "Invalid UTM operation exception"; }
307 virtual std::string GetExceptionName()
const
308 {
return "Invalid UTM zone exception"; }
bool operator==(const UTMPoint &rhs) const
equality operator
UTMPoint(const UTMPoint &theUTMPoint, const ReferenceEllipsoid::EllipsoidID theEllipsoidID)
Construct UTMPoint with an alternative reference ellipsoid.
Base class for all exceptions used in the auger offline code.
UTMPoint(const Point &thePoint, const ReferenceEllipsoid &theEllipsoid)
Construct UTMPoint from cartesian point with given reference ellipsoid.
boost::tuple< double, double, double, int, char > GetCoordinates() const
Get norting, easting, height, zone, and band.
Class to hold and convert a point in geodetic coordinates.
static int ZoneFromLatitudeLongitude(const double theLatitude, const double theLongitude)
Calculate zone number from latitude and longitude.
UTMPoint(const Point &thePoint, const ReferenceEllipsoid::EllipsoidID theEllipsoidID)
Construct UTMPoint from cartesian point with named reference ellipsoid.
void SetFromOtherDatum(const UTMPoint &theUTMPoint)
Datum transformation.
int GetZone() const
Get the zone.
char GetBand() const
Get the band.
double GetNorthing() const
Get the northing.
Report attempts to use invalid UTM zone.
Stream & operator<<(Stream &s, MessageLoggerConfig &mlc)
Applies the configuration to the given stream.
void VerifyZone()
verify zone and throw exception if out of bounds
UTMPoint(const UTMPoint &theUTMPoint, const ReferenceEllipsoid &theEllipsoid)
Construct UTMPoint with an alternative reference ellipsoid.
boost::shared_ptr< const CoordinateTransformer > CoordinateSystemPtr
Shared pointer for coordinate systems.
Reference ellipsoids for UTM transformations.
UTMPoint(const double theNorthing, const double theEasting, const double theHeight, const int theZone, const char theBand, const ReferenceEllipsoid::EllipsoidID theEllipsoidID)
Construct UTMPoint from the UTM information, ellipsoid by name.
double GetHeight() const
Get the height.
ZoneRange
range of zone numbers
double GetEasting() const
Get the easting.
UTMPoint(const double theLatitude, const double theLongitude, const double theHeight, const ReferenceEllipsoid::EllipsoidID theEllipsoidID)
Construct UTMPoint from geodetic Coordinates with named ellipsoid.
Report attempts to use invalid UTM zone.
int fZone
zone runs from 1 to 60
bool operator!=(const UTMPoint &rhs) const
inequality operator
boost::tuple< double, double, double, int > GetCoordinates4() const
Get norting, easting, height, and zone.
boost::tuple< double, double, double > GetCoordinates3() const
Get norting, easting, and height.
Report problems in UTM handling.
~UTMPoint()
Destructor - should be virtual for base classes.
const ReferenceEllipsoid & GetEllipsoid() const
Get the reference ellipsoid.
const ReferenceEllipsoid * fEllipsoid
UTMPoint(const double theLatitude, const double theLongitude, const double theHeight, const ReferenceEllipsoid &theEllipsoid)
Construct UTMPoint from geodetic Coordinates with given ellipsoid.
UTMPoint(const double theNorthing, const double theEasting, const double theHeight, const int theZone, const char theBand, const ReferenceEllipsoid &theEllipsoid)
Construct UTMPoint from the UTM information.
char fBand
Letter indicating band, C-X, w/o O, I.
void SetFromLatitudeLongitude(const double theLatitude, const double theLongitude)
Construction from geodetic Latitude and Longitude (height identical)
utl::CoordinateSystemPtr Get(const std::string &id)
Get a well-known Coordinate System.
static char BandFromLatitude(const double theLatitude)
Calculate band letter from latitude and longitude.
EllipsoidID
ID's of known reference ellipsoid's.
void SetFromCartesian(const Point &thePoint)
Construction from Cartesian coordinates.
Point GetPoint(const CoordinateSystemPtr &theCS=CoordinateSystemPtr()) const
Get a cartesian point from an UTMPoint.
boost::tuple< double, double, double > GetGeodeticCoordinates() const
Get geodetic latitude, longitude, height.