GDAL

gdalalg_vector_make_point.h
1/******************************************************************************
2 *
3 * Project: GDAL
4 * Purpose: "gdal vector make-point"
5 * Author: Dan Baston
6 *
7 ******************************************************************************
8 * Copyright (c) 2025, ISciences LLC
9 *
10 * SPDX-License-Identifier: MIT
11 ****************************************************************************/
12
13#ifndef GDALALG_VECTOR_MAKE_POINT_INCLUDED
14#define GDALALG_VECTOR_MAKE_POINT_INCLUDED
15
16#include "gdalalg_vector_geom.h"
17
19
20/************************************************************************/
21/* GDALVectorMakePointAlgorithm */
22/************************************************************************/
23
24 class GDALVectorMakePointAlgorithm /* non final */
25 : public GDALVectorPipelineStepAlgorithm
26{
27 public:
28 static constexpr const char *NAME = "make-point";
29 static constexpr const char *DESCRIPTION =
30 "Create point geometries from attribute fields";
31 static constexpr const char *HELP_URL =
32 "/programs/gdal_vector_make_point.html";
33
34 explicit GDALVectorMakePointAlgorithm(bool standaloneStep = false);
35
36 private:
37 bool RunStep(GDALPipelineStepRunContext &ctxt) override;
38
39 std::string m_xField{};
40 std::string m_yField{};
41 std::string m_zField{};
42 std::string m_mField{};
43 std::string m_dstCrs{};
44};
45
46/************************************************************************/
47/* GDALVectorMakePointAlgorithmStandalone */
48/************************************************************************/
49
50 class GDALVectorMakePointAlgorithmStandalone final
51 : public GDALVectorMakePointAlgorithm
52{
53 public:
54 GDALVectorMakePointAlgorithmStandalone()
55 : GDALVectorMakePointAlgorithm(/* standaloneStep = */ true)
56 {
57 }
58
59 ~GDALVectorMakePointAlgorithmStandalone() override;
60};
61
63
64#endif /* GDALALG_VECTOR_MAKE_POINT_INCLUDED */