13#ifndef GDALALG_VECTOR_CONCAT_INCLUDED
14#define GDALALG_VECTOR_CONCAT_INCLUDED
16#include "gdalalg_vector_pipeline.h"
19#include "ogrlayerpool.h"
27class GDALVectorConcatAlgorithm
28 :
public GDALVectorPipelineStepAlgorithm
31 static constexpr const char *NAME =
"concat";
32 static constexpr const char *DESCRIPTION =
"Concatenate vector datasets.";
33 static constexpr const char *HELP_URL =
"/programs/gdal_vector_concat.html";
35 explicit GDALVectorConcatAlgorithm(
bool bStandalone =
false);
36 ~GDALVectorConcatAlgorithm()
override;
38 bool CanBeFirstStep()
const override
44 bool RunStep(GDALPipelineStepRunContext &ctxt)
override;
45 bool RunImpl(GDALProgressFunc pfnProgress,
void *pProgressData)
override;
47 std::string m_layerNameTemplate{};
48 std::string m_sourceLayerFieldName{};
49 std::string m_sourceLayerFieldContent{};
50 std::string m_mode =
"merge-per-layer-name";
51 std::string m_fieldStrategy =
"union";
52 std::string m_srsCrs{};
53 std::string m_dstCrs{};
55 std::unique_ptr<OGRLayerPool> m_poLayerPool{};
56 std::vector<std::unique_ptr<OGRLayer>> m_tempLayersKeeper{};
63class GDALVectorConcatAlgorithmStandalone final
64 :
public GDALVectorConcatAlgorithm
67 GDALVectorConcatAlgorithmStandalone()
68 : GDALVectorConcatAlgorithm( true)
72 ~GDALVectorConcatAlgorithmStandalone()
override;
Classes related to registration of format support, and opening datasets.