Libosmium  2.1.0
Fast and flexible C++ library for working with OpenStreetMap data
Classes | Functions | Variables
osmium::util Namespace Reference

Helpful utility classes and functions not strictly OSM related. More...

Classes

class  Options
 
class  VerboseOutput
 

Functions

template<typename T >
double2string (T iterator, double value, int precision)
 
void double2string (std::string &out, double value, int precision)
 

Variables

constexpr int max_double_length = 20
 

Detailed Description

Helpful utility classes and functions not strictly OSM related.

Function Documentation

template<typename T >
T osmium::util::double2string ( iterator,
double  value,
int  precision 
)
inline

Write double to iterator, removing superfluous '0' characters at the end. The decimal dot will also be removed if necessary.

Template Parameters
Titerator type
Parameters
iteratoroutput iterator
valuethe value that should be written
precisionmax number of digits after the decimal point (must be <= 17)
void osmium::util::double2string ( std::string &  out,
double  value,
int  precision 
)
inline

Write double to string, removing superfluous '0' characters at the end. The decimal dot will also be removed if necessary.

Parameters
outstring
valuethe value that should be written
precisionmax number of digits after the decimal point

Variable Documentation

constexpr int osmium::util::max_double_length = 20