GeoDesk for C++
Fast and storage-efficient spatial database engine for OpenStreetMap features
Loading...
Searching...
No Matches
geodesk::FixedLonLat Class Reference

A WGS-84 coordinate pair in 100-nanodegree fixed-point precision. More...

#include <FixedLonLat.h>

Public Member Functions

 FixedLonLat ()=default
 
constexpr FixedLonLat (int32_t lon100n, int32_t lat100n)
 
 FixedLonLat (double lon, double lat)
 
 FixedLonLat (Coordinate c)
 
double lon () const noexcept
 
double lat () const noexcept
 
int32_t lon100nd () const noexcept
 
int32_t lat100nd () const noexcept
 
char * format (char *buf, int prec=7) const
 
template<typename Stream >
void format (Stream &out) const
 
std::string toString () const
 
bool operator== (const FixedLonLat &) const noexcept=default
 
bool operator!= (const FixedLonLat &other) const noexcept=default
 

Detailed Description

A WGS-84 coordinate pair in 100-nanodegree fixed-point precision.

Constructor & Destructor Documentation

◆ FixedLonLat() [1/4]

geodesk::FixedLonLat::FixedLonLat ( )
default

◆ FixedLonLat() [2/4]

geodesk::FixedLonLat::FixedLonLat ( int32_t lon100n,
int32_t lat100n )
inlineexplicitconstexpr

◆ FixedLonLat() [3/4]

geodesk::FixedLonLat::FixedLonLat ( double lon,
double lat )
inlineexplicit

◆ FixedLonLat() [4/4]

geodesk::FixedLonLat::FixedLonLat ( Coordinate c)
inline

Member Function Documentation

◆ format() [1/2]

char * geodesk::FixedLonLat::format ( char * buf,
int prec = 7 ) const
inline

◆ format() [2/2]

template<typename Stream >
void geodesk::FixedLonLat::format ( Stream & out) const
inline

◆ lat()

double geodesk::FixedLonLat::lat ( ) const
inlinenoexcept

◆ lat100nd()

int32_t geodesk::FixedLonLat::lat100nd ( ) const
inlinenoexcept

◆ lon()

double geodesk::FixedLonLat::lon ( ) const
inlinenoexcept

◆ lon100nd()

int32_t geodesk::FixedLonLat::lon100nd ( ) const
inlinenoexcept

◆ operator!=()

bool geodesk::FixedLonLat::operator!= ( const FixedLonLat & other) const
defaultnoexcept

◆ operator==()

bool geodesk::FixedLonLat::operator== ( const FixedLonLat & ) const
defaultnoexcept

◆ toString()

std::string geodesk::FixedLonLat::toString ( ) const
inline

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