14#ifndef OGREDITABLELAYER_H_INCLUDED
15#define OGREDITABLELAYER_H_INCLUDED
18#include "ogrlayerdecorator.h"
22class CPL_DLL IOGREditableLayerSynchronizer
25 virtual ~IOGREditableLayerSynchronizer();
31class CPL_DLL OGREditableLayer :
public OGRLayerDecorator
36 IOGREditableLayerSynchronizer *m_poSynchronizer;
37 bool m_bTakeOwnershipSynchronizer;
40 std::set<GIntBig> m_oSetCreated{};
41 std::set<GIntBig> m_oSetEdited{};
42 std::set<GIntBig> m_oSetDeleted{};
43 std::set<GIntBig>::iterator m_oIter{};
44 std::set<CPLString> m_oSetDeletedFields{};
46 bool m_bStructureModified;
47 bool m_bSupportsCreateGeomField;
48 bool m_bSupportsCurveGeometries;
49 std::map<CPLString, int> m_oMapEditableFDefnFieldNameToIdx{};
52 OGRFeature *poSrcFeature,
bool bCanStealSrcFeature,
53 bool bHideDeletedFields);
55 int GetSrcGeomFieldIndex(
int iGeomField);
58 OGREditableLayer(
OGRLayer *poDecoratedLayer,
59 bool bTakeOwnershipDecoratedLayer,
60 IOGREditableLayerSynchronizer *poSynchronizer,
61 bool bTakeOwnershipSynchronizer);
62 virtual ~OGREditableLayer();
64 void SetNextFID(
GIntBig nNextFID);
65 void SetSupportsCreateGeomField(
bool SupportsCreateGeomField);
66 void SetSupportsCurveGeometries(
bool bSupportsCurveGeometries);
69 virtual void SetSpatialFilter(
OGRGeometry *)
override;
70 virtual void SetSpatialFilterRect(
double dfMinX,
double dfMinY,
71 double dfMaxX,
double dfMaxY)
override;
72 virtual void SetSpatialFilter(
int iGeomField,
OGRGeometry *)
override;
73 virtual void SetSpatialFilterRect(
int iGeomField,
double dfMinX,
74 double dfMinY,
double dfMaxX,
75 double dfMaxY)
override;
77 virtual OGRErr SetAttributeFilter(
const char *)
override;
78 virtual bool GetArrowStream(
struct ArrowArrayStream *out_stream,
81 virtual void ResetReading()
override;
89 const int *panUpdatedFieldsIdx,
90 int nUpdatedGeomFieldsCount,
91 const int *panUpdatedGeomFieldsIdx,
92 bool bUpdateStyleString)
override;
100 virtual GIntBig GetFeatureCount(
int bForce = TRUE)
override;
102 int bForce = TRUE)
override;
105 virtual int TestCapability(
const char *)
override;
108 int bApproxOK = TRUE)
override;
109 virtual OGRErr DeleteField(
int iField)
override;
110 virtual OGRErr ReorderFields(
int *panMap)
override;
112 int nFlags)
override;
114 AlterGeomFieldDefn(
int iGeomField,
116 int nFlags)
override;
119 int bApproxOK = TRUE)
override;
121 virtual OGRErr SyncToDisk()
override;
123 virtual OGRErr StartTransaction()
override;
124 virtual OGRErr CommitTransaction()
override;
125 virtual OGRErr RollbackTransaction()
override;
127 virtual const char *GetGeometryColumn()
override;
Simple container for a bounding region (rectangle)
Definition: ogr_core.h:45
Definition of a feature class or feature layer.
Definition: ogr_feature.h:501
A simple feature, including geometry and attributes.
Definition: ogr_feature.h:877
Definition of an attribute of an OGRFeatureDefn.
Definition: ogr_feature.h:95
Definition of a geometry field of an OGRFeatureDefn.
Definition: ogr_feature.h:330
Abstract base class for all geometry classes.
Definition: ogr_geometry.h:361
This class represents a layer of simple features, with access methods.
Definition: ogrsf_frmts.h:58
This class represents an OpenGIS Spatial Reference System, and contains methods for converting betwee...
Definition: ogr_spatialref.h:153
#define CPL_DISALLOW_COPY_ASSIGN(ClassName)
Helper to remove the copy and assignment constructors so that the compiler will not generate the defa...
Definition: cpl_port.h:1030
char ** CSLConstList
Type of a constant null-terminated list of nul terminated strings.
Definition: cpl_port.h:1179
long long GIntBig
Large signed integer type (generally 64-bit integer type).
Definition: cpl_port.h:199
OGRwkbGeometryType
List of well known binary geometry types.
Definition: ogr_core.h:407
int OGRErr
Type for a OGR error.
Definition: ogr_core.h:371