Libosmium: osmium::relations Namespace Reference

Libosmium Fast and flexible C++ library for working with OpenStreetMap data

Loading...
Searching...
No Matches
Classes | Functions
osmium::relations Namespace Reference

Code related to the assembly of OSM relations. More...

## Classes
class | Collector
class | MembersDatabase
class | MembersDatabaseCommon
class | RelationHandle
struct | relations_manager_memory_usage
class | RelationsDatabase
class | RelationsManager
class | RelationsManagerBase
class | SecondPassHandler

## Functions
template<typename ... TManager>
void | read_relations (const osmium::io::File &file, TManager &...managers)
template<typename ... TManager>
void | read_relations (osmium::ProgressBar &progress_bar, const osmium::io::File &file, TManager &...managers)
template<typename TStream>
void | print_used_memory (TStream &stream, const relations_manager_memory_usage &mu)

## Detailed Description

Code related to the assembly of OSM relations.

## Function Documentation

## ◆ print_used_memory()

template<typename TStream>

void osmium::relations::print_used_memory | ( | TStream & | stream,
|  | const relations_manager_memory_usage & | mu )

Prints relations managers memory usage numbers to the specified stream.

Template Parameters

  TStream | Output stream type (like std::cout, std::cerr, or osmium::VerboseOutput).

Parameters

  stream | Reference to stream where the output should go.
  mu | Memory usage data as returned by the used_memory() functions of various relations managers.

## ◆ read_relations() [1/2]

template<typename ... TManager>

void osmium::relations::read_relations | ( | const osmium::io::File & | file,
|  | TManager &... | managers )

Read relations from file and feed them into all the managers specified as parameters. Opens an osmium::io::Reader internally with the file parameter.

After the file is read, the prepare_for_lookup() function is called on all the managers making them ready for querying the data they have stored.

Template Parameters

  TManager | Any number of relation manager types.

Parameters

  file | The file that should be opened with an osmium::io::Reader.
  managers | Relation managers we want the relations to be sent to.

## ◆ read_relations() [2/2]

template<typename ... TManager>

void osmium::relations::read_relations | ( | osmium::ProgressBar & | progress_bar,
|  | const osmium::io::File & | file,
|  | TManager &... | managers )

Read relations from file and feed them into all the managers specified as parameters. Opens an osmium::io::Reader internally with the file parameter.

After the file is read, the prepare_for_lookup() function is called on all the managers making them ready for querying the data they have stored.

Template Parameters

  TManager | Any number of relation manager types.

Parameters

  progress_bar | Reference to osmium::ProgressBar object that will be updated while reading the data.
  file | The file that should be opened with an osmium::io::Reader.
  managers | Relation managers we want the relations to be sent to.