Module Contents


Bases: object

CONDUITS_LAYERS = ['manholes', 'cableentries']
get_proj(self, srid)
get_db_point(self, x, y, srid=None)

Return GeoJSON Point translated to database projection :param x: :param y: :param srid: :return:

get_layer(self, name)
get_default_zoom(self, layer, object=None)
get_bbox(self, x0, y0, x1, y1, srid)
get_layer_objects(self, layer, x0, y0, x1, y1, srid)

Extract GeoJSON from bounding box


Returns a list of ids of conduits-related layers manholes/cableentries/etc

transform(self, data, src_srid, dst_srid)
get_connection_layer(self, layer, x0, y0, x1, y1, srid)

Build line connections

find_nearest(self, point, layers)

Find and return nearest object :param point: GeoJSON Point or tuple of (x, y) or (x, y, srid) :param layers: List of layer instances or layer names

find_nearest_d(self, point, layers)

Like find_nearest but return a tuple of (Object, distance)