VR-Forces 4.1 Class Documentation
mtFltGridDs.h
Go to the documentation of this file.
1 /*******************************************************************************
2 ** Copyright (c) 2005 MAK Technologies, Inc.
3 ** All rights reserved.
4 *******************************************************************************/
5 /*******************************************************************************
6 ** $RCSfile: mtFltGridDs.h,v $ $Revision: 1.15 $ $State: Exp $
7 *******************************************************************************/
8 
9 #ifndef mtFltGridDs_H_
10 #define mtFltGridDs_H_
11 
12 //
13 // \file mtFltGridDs.h
14 // \brief Represents an abstraction of a GridDataSet node inside a Metaflight file.
15 //
16 
17 #include "mtflt/mtfltDefines.h"
18 #include "mtflt/mtFltDs.h"
19 #include <vlutil/vlConfig.h>
20 #include <vector>
21 #include <string>
22 class DtMtFltGridStack;
23 
24 using namespace std;
25 
26 
27 // \brief Represents an abstraction of a GridDataSet node inside a Metaflight file.
28 // A GridDataset is an abstract class that represents a Dataset with geographic area
29 // that is subdivided into a multi-leveled grid (a GridStack)
31 {
32 public:
33 
34  // Default constructor.
35  DtMtFltGridDs();
36 
37  // Destructor
38  virtual ~DtMtFltGridDs();
39 
40  // Copy constructor
41  DtMtFltGridDs(const DtMtFltGridDs& node);
42 
43  // Assignment operator
44  DtMtFltGridDs& operator=(const DtMtFltGridDs& orig);
45 
46  // Overrides the \p DtMtFltNode::readNode method to read the
47  // common information to all GridDataSet nodes in the Metaflight file.
48  // \param root pointer to the root node of the document
49  // \param node pointer to the xml node that will be read
50  // \return \b true if success reading the node. \b false otherwise.
51  virtual bool readNode(const xmlNodePtr root, xmlNodePtr node);
52 
53  // Returns the grid stack associated with the Dataset
54  virtual const DtMtFltGridStack* gridStack() const;
55 
56  // Returns a vector with the filenames that conform this dataset
57  // \param mftFilename name of the metaflight file
58  // \param files vector of strings containing all the filenames with the
59  // highest level of detail that match the filenamepattern in this dataset.
60  virtual bool files(const DtFilename& mftFilename, vector<string>& files);
61 
62 protected:
63 
65  //list< mfCoordSys* > m_CoordSysUsed;
66 
68  bool DtReplaceString(string& source, const string oldstr, const string newstr);
69 
72  bool DtReplaceString(string& source, const string oldstr, int newval);
73 
75  bool hasEnvironmentVariable(DtString& rootPath, DtString& envVar);
76 
78  void getRootPath(const DtFilename& mftFilename, DtString &rp);
79 
81  void solveEnvironmentVariable(DtString& rootPath, const DtString envVar);
82 
84  void solveStaticAttributesFilePattern(string& filePattern);
85 };
86 
87 #endif

Document ID: Generated on Tue Jan 29 18:21:16 EST 2013 from SVN revision 123193
Copyright © 2005-2013 VT MÄK Inc. All Rights Reserved (www.mak.com)