163 friend class AggregationElement;
164 friend class AttrTableLazyPtr;
165 friend class AttributeElement;
166 friend class DimensionElement;
167 friend class ExplicitElement;
168 friend class NetcdfElement;
169 friend class ReadMetadataElement;
170 friend class RemoveElement;
171 friend class ScanElement;
172 friend class ValuesElement;
173 friend class VariableAggElement;
174 friend class VariableElement;
229 virtual void onStartDocument();
230 virtual void onEndDocument();
238 const std::string& uri);
252 bool isScopeAtomicAttribute()
const;
255 bool isScopeAttributeContainer()
const;
258 bool isScopeSimpleVariable()
const;
261 bool isScopeCompositeVariable()
const;
264 bool isScopeVariable()
const;
267 bool isScopeGlobal()
const;
270 bool isScopeNetcdf()
const;
273 bool isScopeAggregation()
const;
278 bool withinNetcdf()
const;
284 bool withinVariable()
const;
291 NetcdfElement* getCurrentDataset()
const;
305 void setCurrentDataset(NetcdfElement* dataset);
308 NetcdfElement* getRootDataset()
const;
312 DDS* getDDSForCurrentDataset()
const;
321 void pushCurrentDataset(NetcdfElement* dataset);
330 void addChildDatasetToCurrentDataset(NetcdfElement* dataset);
338 void popCurrentDataset(NetcdfElement* dataset);
343 bool parsingDataRequest()
const;
348 void resetParseState();
357 bool isNameAlreadyUsedAtCurrentScope(
const std::string& name);
366 BaseType* getVariableInCurrentVariableContainer(
const string& name);
375 BaseType* getVariableInContainer(
const string& varName, BaseType* pContainer);
384 BaseType* getVariableInDDS(
const string& varName);
400 void addCopyOfVariableAtCurrentScope(BaseType& varTemplate);
406 void deleteVariableAtCurrentScope(
const string& name);
411 BaseType* getCurrentVariable()
const;
417 void setCurrentVariable(BaseType* pVar);
425 static bool typeCheckDAPVariable(
const BaseType& var,
const string& expectedType);
435 AttrTable* getCurrentAttrTable()
const;
442 void setCurrentAttrTable(AttrTable* pAT);
448 AttrTable* getGlobalAttrTable()
const;
454 bool attributeExistsAtCurrentScope(
const string& name)
const;
461 bool findAttribute(
const string& name, AttrTable::Attr_iter& attr)
const;
466 void clearAllAttrTables(DDS* dds);
469 void clearVariableMetadataRecursively(BaseType* var);
476 int tokenizeAttrValues(
vector<string>& tokens,
const string& values,
const string& dapAttrTypeName,
477 const string& separator);
487 int tokenizeValuesForDAPType(
vector<string>& tokens,
const string& values, AttrType dapType,
488 const string& separator);
497 void printScope()
const;
500 string getScopeString()
const;
503 string getTypedScopeString()
const;
506 int getScopeDepth()
const;
522 typedef std::vector<NCMLElement*>::const_reverse_iterator ElementStackConstIterator;
523 ElementStackConstIterator getElementStackBegin()
const
525 return _elementStack.rbegin();
527 ElementStackConstIterator getElementStackEnd()
const
529 return _elementStack.rend();
535 void clearElementStack();
538 void processStartNCMLElement(
const std::string& name,
const XMLAttributeMap& attrs);
541 void processEndNCMLElement(
const std::string& name);
546 const DimensionElement* getDimensionAtLexicalScope(
const string& dimName)
const;
552 string printAllDimensionsAtLexicalScope()
const;
568 bool isParsingOtherXML()
const;
607 static bool sThrowExceptionOnUnknownElements;
629 NetcdfElement* _rootDataset;
632 NetcdfElement* _currentDataset;
640 AttrTableLazyPtr _pCurrentTable;
645 std::vector<NCMLElement*> _elementStack;
663 int _currentParseLine;
void parseInto(const string &ncmlFilename, agg_util::DDSLoader::ResponseType responseType, BESDapResponse *response)
Same as parse, but the response object to parse into is passed down by the caller rather than created...
std::unique_ptr< BESDapResponse > parse(const std::string &ncmlFilename, agg_util::DDSLoader::ResponseType type)
Parse the NcML filename, returning a newly allocated DDS response containing the underlying dataset t...