osmium::index::MapFactory< TId, TValue > Class Template Reference

`#include <map.hpp>`

## Public Types

typedef TId | id_type
typedef TValue | value_type
typedef osmium::index::map::Map< id_type, value_type > | map_type
typedef std::function< map_type *(const std::vector< std::string > &)> | create_map_func

## Public Member Functions

bool | register_map (const std::string &map_type_name, create_map_func func)
bool | has_map_type (const std::string &map_type_name) const
std::vector< std::string > | map_types () const
std::unique_ptr< map_type > | create_map (const std::string &config_string) const

## Static Public Member Functions

static MapFactory< id_type, value_type > & | instance ()

## Private Member Functions

| MapFactory ()=default
| MapFactory (const MapFactory &)=delete
MapFactory & | operator= (const MapFactory &)=delete
| MapFactory (MapFactory &&)=delete
MapFactory & | operator= (MapFactory &&)=delete

## Static Private Member Functions

static OSMIUM_NORETURN void | error (const std::string &map_type_name)

## Private Attributes

std::map< const std::string, create_map_func > | m_callbacks

## Member Typedef Documentation

template<typename TId, typename TValue>

typedef std::function<map_type*(const std::vector<std::string>&)> osmium::index::MapFactory< TId, TValue >::create_map_func

template<typename TId, typename TValue>

typedef TId osmium::index::MapFactory< TId, TValue >::id_type

template<typename TId, typename TValue>

typedef osmium::index::map::Map<id_type, value_type> osmium::index::MapFactory< TId, TValue >::map_type

template<typename TId, typename TValue>

typedef TValue osmium::index::MapFactory< TId, TValue >::value_type

## Constructor & Destructor Documentation

template<typename TId, typename TValue>

osmium::index::MapFactory< TId, TValue >::MapFactory | ( |  | ) |

private default

template<typename TId, typename TValue>

osmium::index::MapFactory< TId, TValue >::MapFactory | ( | const MapFactory< TId, TValue > & |  | ) |

private delete

template<typename TId, typename TValue>

osmium::index::MapFactory< TId, TValue >::MapFactory | ( | MapFactory< TId, TValue > && |  | ) |

private delete

## Member Function Documentation

template<typename TId, typename TValue>

std::unique_ptr<map_type> osmium::index::MapFactory< TId, TValue >::create_map | ( | const std::string & | config_string | ) | const

inline

template<typename TId, typename TValue>

static OSMIUM_NORETURN void osmium::index::MapFactory< TId, TValue >::error | ( | const std::string & | map_type_name | ) |

inline static private

template<typename TId, typename TValue>

bool osmium::index::MapFactory< TId, TValue >::has_map_type | ( | const std::string & | map_type_name | ) | const

inline

template<typename TId, typename TValue>

static MapFactory<id_type, value_type>& osmium::index::MapFactory< TId, TValue >::instance | ( |  | ) |

inline static

template<typename TId, typename TValue>

std::vector<std::string> osmium::index::MapFactory< TId, TValue >::map_types | ( |  | ) | const

inline

template<typename TId, typename TValue>

MapFactory& osmium::index::MapFactory< TId, TValue >::operator= | ( | const MapFactory< TId, TValue > & |  | ) |

private delete

template<typename TId, typename TValue>

MapFactory& osmium::index::MapFactory< TId, TValue >::operator= | ( | MapFactory< TId, TValue > && |  | ) |

private delete

template<typename TId, typename TValue>

bool osmium::index::MapFactory< TId, TValue >::register_map | ( | const std::string & | map_type_name,
|  | create_map_func | func
| ) |  |

inline

## Member Data Documentation

template<typename TId, typename TValue>

std::map<const std::string, create_map_func> osmium::index::MapFactory< TId, TValue >::m_callbacks

private

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

- osmium/index/map.hpp