Class: QgsMultiSurface

class qgis.core.QgsMultiSurface

Bases: QgsGeometryCollection

Constructor for an empty multisurface geometry.

QgsMultiSurface(QgsMultiSurface)

Multi surface geometry collection.

Methods

addGeometry

param g

asGml2

param doc

asGml3

param doc

boundary

rtype

QgsAbstractGeometry

calculateBoundingBox

childCount

childGeometry

childPoint

Returns point at index (for geometries without child geometries - i.e. curve / point).

clear

clearCache

clone

rtype

QgsMultiSurface

createEmptyWithSameType

rtype

QgsMultiSurface

fromCollectionWkt

Reads a collection from a WKT string.

fromWkt

param wkt

geometryType

rtype

str

hasChildGeometries

Returns whether the geometry has any child geometries (False for point / curve, True otherwise)

insertGeometry

param g

setZMTypeFromSubGeometry

Updates the geometry type based on whether sub geometries contain z or m values.

surfaceN

Returns the surface with the specified index.

toCurveType

rtype

QgsMultiSurface

wktOmitChildType

Returns whether child type names are omitted from Wkt representations of the collection

addGeometry(self, g: QgsAbstractGeometry)bool
Parameters

g (QgsAbstractGeometry) –

Return type

bool

asGml2(self, doc: QDomDocument, precision: int = 17, ns: str = '', axisOrder: QgsAbstractGeometry.AxisOrder = QgsAbstractGeometry.AxisOrder.XY)QDomElement
Parameters
  • doc (QDomDocument) –

  • precision (int = 17) –

  • ns (str = '') –

  • axisOrder (QgsAbstractGeometry.AxisOrder = QgsAbstractGeometry.AxisOrder.XY) –

Return type

QDomElement

asGml3(self, doc: QDomDocument, precision: int = 17, ns: str = '', axisOrder: QgsAbstractGeometry.AxisOrder = QgsAbstractGeometry.AxisOrder.XY)QDomElement
Parameters
  • doc (QDomDocument) –

  • precision (int = 17) –

  • ns (str = '') –

  • axisOrder (QgsAbstractGeometry.AxisOrder = QgsAbstractGeometry.AxisOrder.XY) –

Return type

QDomElement

boundary(self)QgsAbstractGeometry
Return type

QgsAbstractGeometry

calculateBoundingBox(self)QgsRectangle
childCount(self)int
childGeometry(self, index: int)QgsAbstractGeometry
childPoint(self, index: int)QgsPoint

Returns point at index (for geometries without child geometries - i.e. curve / point)

Note

used for vertex_iterator implementation

New in version 3.0.

clear(self)
clearCache(self)
clone(self)QgsMultiSurface
Return type

QgsMultiSurface

createEmptyWithSameType(self)QgsMultiSurface
Return type

QgsMultiSurface

fromCollectionWkt(self, wkt: str, subtypes: object, defaultChildWkbType: str = '')bool

Reads a collection from a WKT string.

fromWkt(self, wkt: str)bool
Parameters

wkt (str) –

Return type

bool

geometryType(self)str
Return type

str

hasChildGeometries(self)bool

Returns whether the geometry has any child geometries (False for point / curve, True otherwise)

Note

used for vertex_iterator implementation

New in version 3.0.

insertGeometry(self, g: QgsAbstractGeometry, index: int)bool
Parameters
Return type

bool

setZMTypeFromSubGeometry(self, subggeom: QgsAbstractGeometry, baseGeomType: QgsWkbTypes.Type)

Updates the geometry type based on whether sub geometries contain z or m values.

surfaceN(self, index: int)QgsSurface

Returns the surface with the specified index.

An IndexError will be raised if no surface with the specified index exists.

New in version 3.16.

Parameters

index (int) –

Return type

QgsSurface

toCurveType(self)QgsMultiSurface
Return type

QgsMultiSurface

wktOmitChildType(self)bool

Returns whether child type names are omitted from Wkt representations of the collection

New in version 2.12.