[Qgis-developer] Remove editing functions from QgsVectorLayer
Nathan Woodrow
madmanwoo at gmail.com
Tue Apr 16 03:20:32 PDT 2013
More complicated then I thought :)
On Tue, Apr 16, 2013 at 8:01 PM, Jürgen E. <jef at norbit.de> wrote:
> On Tue, 16. Apr 2013 at 19:26:52 +1000, Nathan Woodrow wrote:
> > Personally I'm not a fan of that.
> > Why don't we make startEditing() return a edit buffer/edit session.
> So you
> > could do this:
> > session = layer.editSession()
> > session.addFeature(feature)
> > ...
> > session.commitChanges()
> > This would mean that everyone can keep their own edit buffers and can
> do
> > what they want. Means you could also doing this:
> > with layer.editSession() as session:
> > session.addFeature(...)
> > which will commit the features at the end.
> > - Nathan
>
> And would would those session interact? Does vector layer render
> everything
> that got added in any session and skip everything that was deleted in any
> session? Can stuff added in one session already be removed in an other?
> How would rollback/undo/redo work?
>
>
>
> Jürgen
>
> --
> Jürgen E. Fischer norBIT GmbH Tel. +49-4931-918175-31
> Dipl.-Inf. (FH) Rheinstraße 13 Fax. +49-4931-918175-50
> Software Engineer D-26506 Norden
> http://www.norbit.de
> committ(ed|ing) to Quantum GIS IRC: jef on FreeNode
>
> --
> norBIT Gesellschaft fuer Unternehmensberatung und Informationssysteme mbH
> Rheinstrasse 13, 26506 Norden
> GF: Jelto Buurman, HR: Amtsgericht Emden, HRB 5502
>
> _______________________________________________
> Qgis-developer mailing list
> Qgis-developer at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/qgis-developer
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/qgis-developer/attachments/20130416/5637e86b/attachment.html>
More information about the Qgis-developer
mailing list