|
libosmscout 1.1.1
|
#include <libosmscout-import/include/osmscoutimport/GenLocationIndex.h>

Public Types | |
| using | PostalAreaMap = std::unordered_map<std::string, PostalArea> |
Public Member Functions | |
| RegionMetrics ()=default | |
| RegionPOI (const std::string &name, const ObjectFileRef &object) | |
| bool | operator< (const RegionPOI &other) const |
| RegionAddress (const std::string &name, const ObjectFileRef &object) | |
| bool | operator< (const RegionAddress &other) const |
| std::string | GetName () const |
| PostalArea (const std::string &name) | |
| void | AddLocationObject (const std::string &name, const ObjectFileRef &objectRef) |
| Region () | |
| void | CalculateMinMax () |
| bool | CouldContain (const GeoBox &boundingBox) const |
| bool | CouldContain (const Region ®ion, bool strict) const |
| bool | Contains (Region &child) const |
| GeoBox | GetBoundingBox () const |
| Checks whether child is within this. | |
| std::vector< GeoBox > | GetAreaBoundingBoxes () const |
| void | AddAlias (const RegionAlias &location, const GeoCoord &node) |
| void | AddPOINode (const FileOffset &fileOffset, const std::string &name, bool &added) |
| void | AddPOIArea (const FileOffset &fileOffset, const std::string &name, const std::vector< Point > &nodes, const GeoBox &boundingBox, bool &added) |
| bool | AddPOIWay (const FileOffset &fileOffset, const std::string &name, const std::vector< Point > &nodes, const GeoBox &boundingBox, bool &added) |
| void | AddLocationObject (const std::string &name, const std::string &postalCode, const ObjectFileRef &objectRef) |
| bool | AddLocationArea (const Area &area, const std::vector< Point > &nodes, const std::string &name, const std::string &postalCode, const GeoBox &boundingBox) |
| bool | AddLocationWay (const Way &way, const std::string &name, const std::string &postalCode, const GeoBox &boundingBox) |
| bool | AddRegion (const RegionRef ®ion, bool assume_contains=true) |
| RegionIndex (double cellWidth, double cellheight) | |
| void | IndexRegions (const std::vector< std::list< locidx::RegionRef > > ®ionTree) |
| RegionRef | GetRegionForNode (const RegionRef &rootRegion, const GeoCoord &coord) const |
Public Attributes | |
| uint32_t | minRegionChars =std::numeric_limits<uint32_t>::max() |
| uint32_t | maxRegionChars =0 |
| uint32_t | minRegionWords =std::numeric_limits<uint32_t>::max() |
| uint32_t | maxRegionWords =0 |
| uint32_t | maxPOIWords =0 |
| uint32_t | minLocationChars =std::numeric_limits<uint32_t>::max() |
| uint32_t | maxLocationChars =0 |
| uint32_t | minLocationWords =std::numeric_limits<uint32_t>::max() |
| uint32_t | maxLocationWords =0 |
| uint32_t | maxAddressWords =0 |
| FileOffset | reference |
| Reference to the node that is the alias. | |
| std::string | name |
| The alias itself. | |
| std::string | altName |
| ObjectFileRef | object |
| Object. | |
| std::unordered_map< std::string, size_t > | names |
| map of names in different case used for this location and their use count | |
| FileOffset | dataOffsetOffset |
| Offset of place where the address list offset is stored. | |
| std::list< ObjectFileRef > | objects |
| Objects that represent this location. | |
| std::list< RegionAddress > | addresses |
| Addresses at this location. | |
| std::map< std::string, RegionLocation > | locations |
| list of indexed objects in this region | |
| FileOffset | indexOffset |
| Offset into the index file. | |
| FileOffset | dataOffset |
| Offset into the index file. | |
| ObjectFileRef | reference |
| Reference to the object this area is based on. | |
| std::string | isIn |
| Name of the parent region as stated in OSM (is_in tag). | |
| std::list< RegionAlias > | aliases |
| Location that are represented by this region. | |
| int8_t | level {-1} |
| Admin level or -1 if not set. | |
| std::vector< std::vector< GeoCoord > > | areas |
| the geometric area of this region | |
| std::list< RegionPOI > | pois |
| A list of POIs in this region. | |
| PostalAreaMap | postalAreas |
| Collection of objects without a postal code. | |
| PostalAreaMap::iterator | defaultPostalArea |
| PostalArea for postal code "". | |
| std::list< RegionRef > | regions |
| A list of sub regions. | |
Holds some metrics regarding names in the given region. These metrics are input for some heuristics regarding searching.
An region can contain an number of location nodes. Since they do not have their own area we define the node name as an alias for the containing region, since this is the best approximation.
A POI within a region
An address within a region (normally a house number)
A location within a region. A location is represented by a number of objects. A location holds a list of addresses.
A postal area is a list of locations that are represented by an id.
An region is an area. An region represents a administrative region like a city, a country, ...
The region has a name, is represented by an objects and may have a number of aliases (that also name the region or parts of the region).
It may also have an admin level.
A region consists of a number of areas that represent the region. The areas and the region itself have bounding boxes.
An region can have child regions (suburbs, ...).
The region may have a list of POIs within its area. An region holds a number of postal areas. There is always an (unnamed9 default postal area.
| using osmscout::locidx::CLASS_FINAL::PostalAreaMap = std::unordered_map<std::string, PostalArea> |
| void osmscout::locidx::CLASS_FINAL::AddAlias | ( | const RegionAlias & | location, |
| const GeoCoord & | node ) |
| bool osmscout::locidx::CLASS_FINAL::AddLocationArea | ( | const Area & | area, |
| const std::vector< Point > & | nodes, | ||
| const std::string & | name, | ||
| const std::string & | postalCode, | ||
| const GeoBox & | boundingBox ) |
| void osmscout::locidx::CLASS_FINAL::AddLocationObject | ( | const std::string & | name, |
| const ObjectFileRef & | objectRef ) |
| void osmscout::locidx::CLASS_FINAL::AddLocationObject | ( | const std::string & | name, |
| const std::string & | postalCode, | ||
| const ObjectFileRef & | objectRef ) |
| bool osmscout::locidx::CLASS_FINAL::AddLocationWay | ( | const Way & | way, |
| const std::string & | name, | ||
| const std::string & | postalCode, | ||
| const GeoBox & | boundingBox ) |
| void osmscout::locidx::CLASS_FINAL::AddPOIArea | ( | const FileOffset & | fileOffset, |
| const std::string & | name, | ||
| const std::vector< Point > & | nodes, | ||
| const GeoBox & | boundingBox, | ||
| bool & | added ) |
| void osmscout::locidx::CLASS_FINAL::AddPOINode | ( | const FileOffset & | fileOffset, |
| const std::string & | name, | ||
| bool & | added ) |
| bool osmscout::locidx::CLASS_FINAL::AddPOIWay | ( | const FileOffset & | fileOffset, |
| const std::string & | name, | ||
| const std::vector< Point > & | nodes, | ||
| const GeoBox & | boundingBox, | ||
| bool & | added ) |
| bool osmscout::locidx::CLASS_FINAL::AddRegion | ( | const RegionRef & | region, |
| bool | assume_contains = true ) |
| void osmscout::locidx::CLASS_FINAL::CalculateMinMax | ( | ) |
| bool osmscout::locidx::CLASS_FINAL::Contains | ( | Region & | child | ) | const |
| bool osmscout::locidx::CLASS_FINAL::CouldContain | ( | const GeoBox & | boundingBox | ) | const |
| bool osmscout::locidx::CLASS_FINAL::CouldContain | ( | const Region & | region, |
| bool | strict ) const |
|
inline |
|
inline |
Checks whether child is within this.
| std::string osmscout::locidx::CLASS_FINAL::GetName | ( | ) | const |
| RegionRef osmscout::locidx::CLASS_FINAL::GetRegionForNode | ( | const RegionRef & | rootRegion, |
| const GeoCoord & | coord ) const |
| void osmscout::locidx::CLASS_FINAL::IndexRegions | ( | const std::vector< std::list< locidx::RegionRef > > & | regionTree | ) |
|
inline |
|
inline |
|
inlineexplicit |
| osmscout::locidx::CLASS_FINAL::Region | ( | ) |
|
inline |
| osmscout::locidx::CLASS_FINAL::RegionIndex | ( | double | cellWidth, |
| double | cellheight ) |
|
default |
|
inline |
| std::list<RegionAddress> osmscout::locidx::CLASS_FINAL::addresses |
Addresses at this location.
| std::list<RegionAlias> osmscout::locidx::CLASS_FINAL::aliases |
Location that are represented by this region.
| std::string osmscout::locidx::CLASS_FINAL::altName |
| std::vector<std::vector<GeoCoord> > osmscout::locidx::CLASS_FINAL::areas |
the geometric area of this region
| FileOffset osmscout::locidx::CLASS_FINAL::dataOffset |
Offset into the index file.
| FileOffset osmscout::locidx::CLASS_FINAL::dataOffsetOffset |
Offset of place where the address list offset is stored.
Offset into the index file.
| PostalAreaMap::iterator osmscout::locidx::CLASS_FINAL::defaultPostalArea |
PostalArea for postal code "".
| FileOffset osmscout::locidx::CLASS_FINAL::indexOffset |
Offset into the index file.
| std::string osmscout::locidx::CLASS_FINAL::isIn |
Name of the parent region as stated in OSM (is_in tag).
| int8_t osmscout::locidx::CLASS_FINAL::level {-1} |
Admin level or -1 if not set.
| std::map<std::string,RegionLocation> osmscout::locidx::CLASS_FINAL::locations |
list of indexed objects in this region
| uint32_t osmscout::locidx::CLASS_FINAL::maxAddressWords =0 |
| uint32_t osmscout::locidx::CLASS_FINAL::maxLocationChars =0 |
| uint32_t osmscout::locidx::CLASS_FINAL::maxLocationWords =0 |
| uint32_t osmscout::locidx::CLASS_FINAL::maxPOIWords =0 |
| uint32_t osmscout::locidx::CLASS_FINAL::maxRegionChars =0 |
| uint32_t osmscout::locidx::CLASS_FINAL::maxRegionWords =0 |
| uint32_t osmscout::locidx::CLASS_FINAL::minLocationChars =std::numeric_limits<uint32_t>::max() |
| uint32_t osmscout::locidx::CLASS_FINAL::minLocationWords =std::numeric_limits<uint32_t>::max() |
| uint32_t osmscout::locidx::CLASS_FINAL::minRegionChars =std::numeric_limits<uint32_t>::max() |
| uint32_t osmscout::locidx::CLASS_FINAL::minRegionWords =std::numeric_limits<uint32_t>::max() |
| std::string osmscout::locidx::CLASS_FINAL::name |
| std::unordered_map<std::string, size_t> osmscout::locidx::CLASS_FINAL::names |
map of names in different case used for this location and their use count
| ObjectFileRef osmscout::locidx::CLASS_FINAL::object |
Object.
Object with the given address.
| std::list<ObjectFileRef> osmscout::locidx::CLASS_FINAL::objects |
Objects that represent this location.
| std::list<RegionPOI> osmscout::locidx::CLASS_FINAL::pois |
A list of POIs in this region.
| PostalAreaMap osmscout::locidx::CLASS_FINAL::postalAreas |
Collection of objects without a postal code.
| ObjectFileRef osmscout::locidx::CLASS_FINAL::reference |
Reference to the object this area is based on.
| FileOffset osmscout::locidx::CLASS_FINAL::reference |
Reference to the node that is the alias.
| std::list<RegionRef> osmscout::locidx::CLASS_FINAL::regions |
A list of sub regions.