File: qgsprovidersublayerdetails.sip.in

package info (click to toggle)
qgis 3.40.11%2Bdfsg-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 1,183,800 kB
  • sloc: cpp: 1,595,841; python: 372,637; xml: 23,474; sh: 3,761; perl: 3,664; ansic: 2,257; sql: 2,137; yacc: 1,068; lex: 577; javascript: 540; lisp: 411; makefile: 154
file content (297 lines) | stat: -rw-r--r-- 7,571 bytes parent folder | download | duplicates (14)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
/************************************************************************
 * This file has been generated automatically from                      *
 *                                                                      *
 * src/core/providers/qgsprovidersublayerdetails.h                      *
 *                                                                      *
 * Do not edit manually ! Edit header and run scripts/sipify.py again   *
 ************************************************************************/



class QgsProviderSublayerDetails
{
%Docstring(signature="appended")
Contains details about a sub layer available from a dataset.

This class encapsulates the properties of a single sublayer available
from a dataset, according to a specific data provider.

.. note::

   It is possible that multiple data providers may be able to utilize the same underlying
   sub layer in a single dataset, yet will interpret this layer differently. For instance, a layer
   in a Geospatial PDF document can be interpreted as either a vector layer by the OGR data provider or a raster
   layer by the GDAL provider. The :py:func:`~providerKey` property can be used to determine the data provider
   associated with a :py:class:`QgsProviderSubLayerDetails` instance.

.. versionadded:: 3.22
%End

%TypeHeaderCode
#include "qgsprovidersublayerdetails.h"
%End
  public:

    QString providerKey() const;
%Docstring
Returns the associated data provider key.

.. seealso:: :py:func:`setProviderKey`
%End

    void setProviderKey( const QString &key );
%Docstring
Sets the associated data provider key.

.. seealso:: :py:func:`providerKey`
%End

    Qgis::LayerType type() const;
%Docstring
Returns the layer type.

.. seealso:: :py:func:`setType`
%End

    void setType( Qgis::LayerType type );
%Docstring
Sets the layer ``type``.

.. seealso:: :py:func:`type`
%End

    QString uri() const;
%Docstring
Returns the layer's URI.

.. seealso:: :py:func:`setUri`
%End

    void setUri( const QString &uri );
%Docstring
Sets the layer's ``uri``.

.. seealso:: :py:func:`uri`
%End

    struct LayerOptions
    {

      explicit LayerOptions( const QgsCoordinateTransformContext &transformContext );
%Docstring
Constructor for LayerOptions with ``transformContext``.
%End

      QgsCoordinateTransformContext transformContext;

      bool loadDefaultStyle;

      bool loadAllStoredStyle;
    };

    QgsMapLayer *toLayer( const LayerOptions &options ) const /Factory/;
%Docstring
Creates a new :py:class:`QgsMapLayer` object associated with the
sublayer.

Caller takes ownership of the returned layer.
%End

    QString name() const;
%Docstring
Returns the layer's name.

.. seealso:: :py:func:`setName`
%End

    void setName( const QString &name );
%Docstring
Sets the layer's ``name``.

.. seealso:: :py:func:`name`
%End

    QString description() const;
%Docstring
Returns the layer's description.

.. seealso:: :py:func:`setDescription`
%End

    void setDescription( const QString &description );
%Docstring
Sets the layer's ``description``.

.. seealso:: :py:func:`description`
%End

    Qgis::SublayerFlags flags() const;
%Docstring
Returns the layer's flags, which indicate properties of the layer.

.. seealso:: :py:func:`setFlags`
%End

    void setFlags( Qgis::SublayerFlags newFlags );
%Docstring
Sets the layer's ``flags``, which indicate properties of the layer.

.. seealso:: :py:func:`flags`
%End

    QString driverName() const;
%Docstring
Returns the layer's driver name.

This is supported only for providers which handle multiple drivers.

.. seealso:: :py:func:`setDriverName`
%End

    void setDriverName( const QString &driver );
%Docstring
Sets the layer's ``driver`` name.

.. seealso:: :py:func:`driverName`
%End

    QStringList path() const;
%Docstring
Returns the path to the sublayer.

This is an internal path, relative to the dataset itself. It can be used
to encapsulate the hierarchy of a dataset which organises layers in
schemas or in an internal folder structure.

.. seealso:: :py:func:`setPath`
%End

    void setPath( const QStringList &path );
%Docstring
Sets the ``path`` to the sublayer.

This is an internal path, relative to the dataset itself. It can be used
to encapsulate the hierarchy of a dataset which organises layers in
schemas or in an internal folder structure.

.. seealso:: :py:func:`path`
%End

    long long featureCount() const;
%Docstring
Returns the layer's feature count.

Will return :py:class:`Qgis`.FeatureCountState.UnknownCount or
:py:class:`Qgis`.FeatureCountState.Uncounted if no feature count is
applicable or available.

.. seealso:: :py:func:`setFeatureCount`
%End

    void setFeatureCount( long long count );
%Docstring
Sets the layer's feature ``count``.

Set to :py:class:`Qgis`.FeatureCountState.UnknownCount or
:py:class:`Qgis`.FeatureCountState.Uncounted if no feature count is
applicable or available.

.. seealso:: :py:func:`featureCount`
%End

    Qgis::WkbType wkbType() const;
%Docstring
Returns the layer's WKB type, or :py:class:`QgsWkbTypes`.Unknown if the
WKB type is not application or unknown.

.. seealso:: :py:func:`setWkbType`
%End

    void setWkbType( Qgis::WkbType type );
%Docstring
Set the layer's WKB ``type``.

Set to :py:class:`QgsWkbTypes`.Unknown if the WKB type is not
application or unknown.

.. seealso:: :py:func:`wkbType`
%End

    QString geometryColumnName() const;
%Docstring
Returns the layer's geometry column name, or an empty string if not
applicable.

.. seealso:: :py:func:`setGeometryColumnName`
%End

    void setGeometryColumnName( const QString &name );
%Docstring
Sets the layer's geometry column ``name``.

Set to an empty string if not applicable.

.. seealso:: :py:func:`geometryColumnName`
%End

    SIP_PYOBJECT __repr__();
%MethodCode
    QString str = QStringLiteral( "<QgsProviderSublayerDetails: %1 - %2>" ).arg( sipCpp->providerKey(), sipCpp->name() );
    sipRes = PyUnicode_FromString( str.toUtf8().constData() );
%End

    int layerNumber() const;
%Docstring
Returns the associated layer number, for providers which order
sublayers.

.. seealso:: :py:func:`setLayerNumber`
%End

    void setLayerNumber( int number );
%Docstring
Sets the associated layer ``number``, for providers which order
sublayers.

.. seealso:: :py:func:`layerNumber`
%End

    void setSkippedContainerScan( bool skipped );
%Docstring
Set to ``True`` if the layer is a potential dataset container and an
in-depth scan of its contents was skipped.

.. seealso:: :py:func:`skippedContainerScan`
%End

    bool skippedContainerScan() const;
%Docstring
Returns ``True`` if the layer is a potential dataset container and an
in-depth scan of its contents was skipped.

.. seealso:: :py:func:`setSkippedContainerScan`
%End

    QgsMimeDataUtils::Uri toMimeUri() const;
%Docstring
Converts the sublayer details to a :py:class:`QgsMimeDataUtils`.Uri
representing the sublayer.

.. versionadded:: 3.28
%End

    bool operator==( const QgsProviderSublayerDetails &other ) const;
    bool operator!=( const QgsProviderSublayerDetails &other ) const;

};




/************************************************************************
 * This file has been generated automatically from                      *
 *                                                                      *
 * src/core/providers/qgsprovidersublayerdetails.h                      *
 *                                                                      *
 * Do not edit manually ! Edit header and run scripts/sipify.py again   *
 ************************************************************************/