29#ifndef __NCML_MODULE_NCML_UTIL_H__
30#define __NCML_MODULE_NCML_UTIL_H__
63#define SAFE_DELETE(a) { delete (a); (a) = 0; }
86 static int tokenize(
const std::string& str, std::vector<std::string>& tokens,
87 const std::string& delimiters =
" \t");
90 static int tokenizeChars(
const std::string& str, std::vector<std::string>& tokens);
95 static bool isAscii(
const std::string& str);
119 static void trimAll(std::vector<std::string>& tokens,
const std::string& trimChars = WHITESPACE);
127 static bool toUnsignedInt(
const std::string& stringVal,
unsigned int& oVal);
151 static void hackGlobalAttributesForDAP2(libdap::AttrTable &global_attributes,
152 const std::string &global_container_name);
Represents an OPeNDAP DAP response object within the BES.
static int tokenize(const std::string &str, std::vector< std::string > &tokens, const std::string &delimiters=" \t")
static libdap::DDS * getDDSFromEitherResponse(BESDapResponse *response)
static bool isAllWhitespace(const std::string &str)
static void trim(std::string &str, const std::string &trimChars=WHITESPACE)
static int tokenizeChars(const std::string &str, std::vector< std::string > &tokens)
static bool toUnsignedInt(const std::string &stringVal, unsigned int &oVal)
static void populateDASFromDDS(libdap::DAS *das, const libdap::DDS &dds_const)
static void trimRight(std::string &str, const std::string &trimChars=WHITESPACE)
static void copyVariablesAndAttributesInto(libdap::DDS *dds_out, const libdap::DDS &dds_in)
static const std::string WHITESPACE
static void setVariableNameProperly(libdap::BaseType *pVar, const std::string &name)
static void trimAll(std::vector< std::string > &tokens, const std::string &trimChars=WHITESPACE)
static bool isAscii(const std::string &str)
static void trimLeft(std::string &str, const std::string &trimChars=WHITESPACE)
NcML Parser for adding/modifying/removing metadata (attributes) to existing local datasets using NcML...