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
|
/************************************************************************
* This file has been generated automatically from *
* *
* src/core/browser/qgslayeritem.h *
* *
* Do not edit manually ! Edit header and run scripts/sipify.py again *
************************************************************************/
class QgsLayerItem : QgsDataItem
{
%Docstring(signature="appended")
Item that represents a layer that can be opened with one of the
providers
%End
%TypeHeaderCode
#include "qgslayeritem.h"
%End
public:
QgsLayerItem( QgsDataItem *parent, const QString &name, const QString &path, const QString &uri, Qgis::BrowserLayerType layerType, const QString &providerKey );
%Docstring
Constructor for QgsLayerItem.
%End
SIP_PYOBJECT __repr__();
%MethodCode
QString str = QStringLiteral( "<QgsLayerItem: \"%1\" %2>" ).arg( sipCpp->name(), sipCpp->path() );
sipRes = PyUnicode_FromString( str.toUtf8().constData() );
%End
virtual bool equal( const QgsDataItem *other );
virtual bool hasDragEnabled() const;
virtual QgsMimeDataUtils::UriList mimeUris() const;
Qgis::LayerType mapLayerType() const;
%Docstring
Returns the associated map layer type.
%End
static Qgis::BrowserLayerType typeFromMapLayer( QgsMapLayer *layer );
%Docstring
Returns the layer item type corresponding to a :py:class:`QgsMapLayer`
``layer``.
.. versionadded:: 3.6
%End
QString uri() const;
%Docstring
Returns layer uri or empty string if layer cannot be created
%End
QStringList supportedCrs() const;
%Docstring
Returns the supported CRS
%End
QStringList supportedFormats() const;
%Docstring
Returns the supported formats
%End
virtual QString comments() const;
%Docstring
Returns comments of the layer
%End
static QString layerTypeAsString( Qgis::BrowserLayerType layerType );
%Docstring
Returns the string representation of the given ``layerType``
.. versionadded:: 3
%End
static QString iconName( Qgis::BrowserLayerType layerType );
%Docstring
Returns the icon name of the given ``layerType``
.. versionadded:: 3
%End
virtual bool deleteLayer() /Deprecated/;
%Docstring
Delete this layer item Use
:py:class:`QgsDataItemGuiProvider`.deleteLayer instead
.. deprecated:: 3.10
%End
protected:
public:
static QIcon iconForWkbType( Qgis::WkbType type );
%Docstring
Returns the icon for a vector layer whose geometry type is provided.
.. versionadded:: 3.18
%End
static QIcon iconPoint();
static QIcon iconLine();
static QIcon iconPolygon();
static QIcon iconTable();
static QIcon iconRaster();
static QIcon iconDefault();
static QIcon iconMesh();
%Docstring
Returns icon for mesh layer type
%End
static QIcon iconVectorTile();
%Docstring
Returns icon for vector tile layer
%End
static QIcon iconPointCloud();
%Docstring
Returns icon for point cloud layer
%End
virtual QString layerName() const;
%Docstring
:return: the layer name
%End
virtual QgsAbstractDatabaseProviderConnection *databaseConnection() const;
const QgsLayerMetadata &layerMetadata() const;
%Docstring
Returns layer's metadata, it may be a default constructed metadata if
metadata is not explicitly set.
.. versionadded:: 3.28
%End
void setLayerMetadata( const QgsLayerMetadata &metadata );
%Docstring
Set layer's ``metadata``.
.. versionadded:: 3.28
%End
};
/************************************************************************
* This file has been generated automatically from *
* *
* src/core/browser/qgslayeritem.h *
* *
* Do not edit manually ! Edit header and run scripts/sipify.py again *
************************************************************************/
|