GDAL

gdaljp2abstractdataset.h
1/******************************************************************************
2 * $Id$
3 *
4 * Project: GDAL
5 * Purpose: GDALGeorefPamDataset with helper to read georeferencing and other
6 * metadata from JP2Boxes
7 * Author: Even Rouault <even dot rouault at spatialys.com>
8 *
9 ******************************************************************************
10 * Copyright (c) 2013, Even Rouault <even dot rouault at spatialys.com>
11 *
12 * SPDX-License-Identifier: MIT
13 ****************************************************************************/
14
15#ifndef GDAL_JP2_ABSTRACT_DATASET_H_INCLUDED
16#define GDAL_JP2_ABSTRACT_DATASET_H_INCLUDED
17
19#include "gdalgeorefpamdataset.h"
20
21 class CPL_DLL GDALJP2AbstractDataset : public GDALGeorefPamDataset
22{
23 char *pszWldFilename = nullptr;
24
25 GDALDataset *poMemDS = nullptr;
26 char **papszMetadataFiles = nullptr;
27 int m_nWORLDFILEIndex = -1;
28 CPLStringList m_aosImageStructureMetadata{};
29
30 CPL_DISALLOW_COPY_ASSIGN(GDALJP2AbstractDataset)
31
32 protected:
33 int CloseDependentDatasets() override;
34
35 virtual VSILFILE *GetFileHandle()
36 {
37 return nullptr;
38 }
39
40 public:
41 GDALJP2AbstractDataset();
42 ~GDALJP2AbstractDataset() override;
43
44 void LoadJP2Metadata(GDALOpenInfo *poOpenInfo,
45 const char *pszOverrideFilename = nullptr,
46 VSILFILE *fpBox = nullptr);
47 void LoadVectorLayers(int bOpenRemoteResources = FALSE);
48
49 char **GetFileList(void) override;
50
51 char **GetMetadata(const char *pszDomain = "") override;
52 const char *GetMetadataItem(const char *pszName,
53 const char *pszDomain = "") override;
54
55 int GetLayerCount() override;
56 OGRLayer *GetLayer(int i) override;
57};
58
60
61#endif /* GDAL_JP2_ABSTRACT_DATASET_H_INCLUDED */
CPLStringList
String list class designed around our use of C "char**" string lists.
Definition: cpl_string.h:436
GDALDataset
A set of associated raster bands, usually from one file.
Definition: gdal_priv.h:495
GDALOpenInfo
Class for dataset open functions.
Definition: gdal_priv.h:293
OGRLayer
This class represents a layer of simple features, with access methods.
Definition: ogrsf_frmts.h:58
CPL_DISALLOW_COPY_ASSIGN
#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
VSIVirtualHandle
Virtual file handle.
Definition: cpl_vsi_virtual.h:47