osm_cartography.geo_map

Class for manipulating GeographicMap data.

Warning

This module is unstable and still evolving. It will probably end up residing in some other package.

class osm_cartography.geo_map.GeoMap(gmap)[source]

GeoMap provides an internal geographic_msgs/GeographicMap representation.

Parameters:gmapgeographic_msgs/GeographicMap message.
bounds()[source]
Returns:geographic_msgs/BoundingBox from the geographic_msgs/GeographicMap message.
header()[source]
Returns:std_msgs/Header from the geographic_msgs/GeographicMap message.
class osm_cartography.geo_map.GeoMapFeatures(geomap)[source]

GeoMapFeatures provides a filtering iterator for the features in a osm_cartography.geo_map.GeoMap.

Parameters:geomapGeoMap object.

GeoMapFeatures provides these standard container operations:

len(features)
Returns :The number of points in the set.
features[uuid]
Returns :The point with key uuid. Raises a KeyError if uuid is not in the set.
uuid in features
Returns :True if features has a key uuid, else False.
uuid not in features

Equivalent to not uuid in features.

iter(features)
Returns :An iterator over all the features. This is a shortcut for iterkeys().

Example:

gm = GeoMap(msg)
gf = GeoMapFeatures(gm)
for feat in gf:
    print str(feat)
next()[source]

Next matching feature.

Returns:geodesy.wu_point.WuPoint object for next point
Raises :StopIteration when finished.

Previous topic

osm_cartography: Geographic mapping using Open Street Map data

Next topic

osm_cartography.xml_map

This Page