Class: QgsGml¶
-
class
qgis.core.
QgsGml
¶ Bases:
PyQt5.QtCore.QObject
This class reads data from a WFS server or alternatively from a GML file. It uses the expat XML parser and an event based model to keep performance high. The parsing starts when the first data arrives, it does not wait until the request is finished *
Methods
Returns features spatial reference system
Gets parsed features for given type name
Read from GML data.
Does the Http GET request to the wfs server Supports only UTF-8, UTF-16, ISO-8859-1, ISO-8859-1 XML encodings.
Gets feature ids map
Signals
Also emit signal with progress and totalSteps together (this is better for the status message) [signal]
dataReadProgress(self, int) [signal]
totalStepsUpdate(self, int) [signal]
-
childEvent
()¶
-
connectNotify
()¶
-
crs
(self) → QgsCoordinateReferenceSystem¶ Returns features spatial reference system
New in version 2.1.
- Return type
-
customEvent
()¶
-
dataProgressAndSteps
¶ Also emit signal with progress and totalSteps together (this is better for the status message) [signal]
-
dataReadProgress
¶ dataReadProgress(self, int) [signal]
-
disconnectNotify
()¶
-
featuresMap
(self) → object¶ Gets parsed features for given type name
- Return type
object
-
getFeatures
(self, data: Union[QByteArray, bytes, bytearray], extent: QgsRectangle = None) → Tuple[int, QgsWkbTypes.Type]¶ Read from GML data. Constructor uri param is ignored Supports only UTF-8, UTF-16, ISO-8859-1, ISO-8859-1 XML encodings.
- Parameters
data (Union[QByteArray) –
extent (
QgsRectangle
= None) –
- Return type
Tuple[int, QgsWkbTypes.Type]
-
getFeaturesUri
(self, uri: str, extent: QgsRectangle = None, userName: str = '', password: str = '', authcfg: str = '') → Tuple[int, QgsWkbTypes.Type]¶ Does the Http GET request to the wfs server Supports only UTF-8, UTF-16, ISO-8859-1, ISO-8859-1 XML encodings.
- Parameters
uri (str) – GML URL
wkbType – wkbType to retrieve
extent (
QgsRectangle
= None) – retrieved extentsuserName (str = '') – username for authentication
password (str = '') – password for authentication
authcfg (str = '') – authentication configuration id
- Return type
Tuple[int, QgsWkbTypes.Type]
- Returns
0 in case of success
Note
available in Python as getFeaturesUri
-
idsMap
(self) → object¶ Gets feature ids map
- Return type
object
-
isSignalConnected
()¶
-
receivers
()¶
-
sender
()¶
-
senderSignalIndex
()¶
-
timerEvent
()¶
-
totalStepsUpdate
¶ totalStepsUpdate(self, int) [signal]
-