18#ifndef NASAKEYWORDHANDLER_H
19#define NASAKEYWORDHANDLER_H
34class CPL_DLL NASAKeywordHandler
36 CPLStringList aosKeywordList{};
38 const char *pszHeaderNext =
nullptr;
40 CPLJSONObject oJSon{};
42 bool m_bStripSurroundingQuotes =
false;
45 bool ReadWord(CPLString &osWord,
bool bStripSurroundingQuotes =
false,
46 bool bParseList =
false,
bool *pbIsString =
nullptr);
47 bool ReadPair(CPLString &osName, CPLString &osValue, CPLJSONObject &oCur);
48 bool ReadGroup(
const std::string &osPathPrefix, CPLJSONObject &oCur,
51 NASAKeywordHandler(
const NASAKeywordHandler &) =
delete;
52 NASAKeywordHandler &operator=(
const NASAKeywordHandler &) =
delete;
56 ~NASAKeywordHandler();
58 void SetStripSurroundingQuotes(
bool bStripSurroundingQuotes)
60 m_bStripSurroundingQuotes = bStripSurroundingQuotes;
63 bool Ingest(
VSILFILE *fp,
int nOffset);
64 bool Parse(
const char *pszStr);
66 const char *GetKeyword(
const char *pszPath,
const char *pszDefault);
67 char **GetKeywordList();
68 CPLJSONObject GetJsonObject()
const;
Interface for read and write JSON documents.
Various convenience functions for working with strings and string lists.
struct VSIVirtualHandle VSILFILE
Opaque type for a FILE that implements the VSIVirtualHandle API.
Definition cpl_vsi.h:141