GDAL

gdalalg_dataset_delete.h
1/******************************************************************************
2 *
3 * Project: GDAL
4 * Purpose: gdal "dataset delete" subcommand
5 * Author: Even Rouault <even dot rouault at spatialys.com>
6 *
7 ******************************************************************************
8 * Copyright (c) 2025, Even Rouault <even dot rouault at spatialys.com>
9 *
10 * SPDX-License-Identifier: MIT
11 ****************************************************************************/
12
13#ifndef GDALALG_DATASET_DELETE_INCLUDED
14#define GDALALG_DATASET_DELETE_INCLUDED
15
16#include "gdalalgorithm.h"
17
19
20/************************************************************************/
21/* GDALDatasetDeleteAlgorithm */
22/************************************************************************/
23
24 class GDALDatasetDeleteAlgorithm final : public GDALAlgorithm
25{
26 public:
27 static constexpr const char *NAME = "delete";
28 static constexpr const char *DESCRIPTION = "Delete dataset(s).";
29 static constexpr const char *HELP_URL =
30 "/programs/gdal_dataset_delete.html";
31
32 static std::vector<std::string> GetAliasesStatic()
33 {
34 return {"rm", "remove"};
35 }
36
37 GDALDatasetDeleteAlgorithm();
38
39 private:
40 std::vector<std::string> m_filename{};
41 std::string m_format{};
42
43 bool RunImpl(GDALProgressFunc, void *) override;
44};
45
47
48#endif
GDALAlgorithm
GDAL algorithm.
Definition gdalalgorithm_cpp.h:2261