I what to create many lines with this code:
v_layer = QgsVectorLayer("LineString", "cable", "memory")
pr = v_layer.dataProvider()
seg = QgsFeature()
seg.setGeometry(QgsGeometry.fromPolyline([line_start, geomPoint]))
pr.addFeatures( [ seg ] )
v_layer.updateExtents()
QgsMapLayerRegistry.instance().addMapLayers([v_layer])
Buth this create one layer for each of this code.
How can I create all in one layer.