Class: QgsVectorLayerEditPassthrough

class qgis.core.QgsVectorLayerEditPassthrough(layer: QgsVectorLayer)

Bases: qgis._core.QgsVectorLayerEditBuffer

addAttribute(self, field: QgsField) → bool
addFeature(self, f: QgsFeature) → bool
addFeatures(self, features: object) → bool
changeAttributeValue(self, fid: int, field: int, newValue: Any, oldValue: Any = None) → bool
changeAttributeValues(self, fid: int, newValues: Dict[int, Any], oldValues: Dict[int, Any]) → bool

Changes values of attributes (but does not commit it).

Returns:true if attributes are well updated, false otherwise

New in version 3.0.

changeGeometry(self, fid: int, geom: QgsGeometry) → bool
childEvent()
commitChanges(self, commitErrors: Iterable[str]) → bool
connectNotify()
customEvent()
deleteAttribute(self, attr: int) → bool
deleteFeature(self, fid: int) → bool
deleteFeatures(self, fids: object) → bool
disconnectNotify()
handleAttributeAdded()
handleAttributeDeleted()
isModified(self) → bool
isSignalConnected()
receivers()
renameAttribute(self, attr: int, newName: str) → bool
rollBack(self)
sender()
senderSignalIndex()
timerEvent()
undoIndexChanged()
update(self, transaction: QgsTransaction, sql: str, name: str) → bool

Update underlying data with a SQL query embedded in a transaction.

Parameters:
  • transaction – Transaction in which the sql query has been run
  • sql – The SQL query updating data
  • name – The name of the undo/redo command
Returns:

true if the undo/redo command is well added to the stack, false otherwise

New in version 3.0.

updateAttributeMapIndex()
updateChangedAttributes()
updateFeatureGeometry()
updateFields()
updateLayerFields()