VAPoR  0.1
DataMgrWB.h
Go to the documentation of this file.
1 //
2 // $Id$
3 //
4 
5 #ifndef _DataMgrWB_h_
6 #define _DataMgrWB_h_
7 
8 
9 #include <vector>
10 #include <string>
11 #include <vapor/DataMgr.h>
12 #include <vapor/WaveletBlock3DRegionReader.h>
13 #include <vapor/common.h>
14 
15 namespace VAPoR {
16 
17 //
30 //
32 
33 public:
34 
35  DataMgrWB(
36  const string &metafile,
37  size_t mem_size
38  );
39 
40  DataMgrWB(
41  const MetadataVDC &metadata,
42  size_t mem_size
43  );
44 
45 
46  virtual ~DataMgrWB() {};
47 
48 protected:
49 
50 
51  //
52  // Metadata methods
53  //
54  virtual void _GetDim(size_t dim[3], int reflevel) const {
55  return(WaveletBlock3DRegionReader::GetDim(dim, reflevel));
56  };
57 
58  virtual void _GetBlockSize(size_t bs[3], int reflevel) const {
60  }
61 
62  virtual int _GetNumTransforms() const {
64  };
65 
66  virtual string _GetCoordSystemType() const {
68  };
69 
70  virtual string _GetGridType() const {
72  };
73 
74  virtual vector<double> _GetExtents(size_t ts) const {
76  };
77 
78  virtual vector <double> _GetTSXCoords(size_t ts) const {
80  }
81 
82  virtual vector <double> _GetTSYCoords(size_t ts) const {
84  }
85 
86  virtual vector <double> _GetTSZCoords(size_t ts) const {
88  }
89 
90  virtual long _GetNumTimeSteps() const {
92  };
93 
94  virtual string _GetMapProjection() const {
96  };
97 
98  virtual vector <string> _GetVariables3D() const {
100  };
101 
102  virtual vector <string> _GetVariables2DXY() const {
104  };
105  virtual vector <string> _GetVariables2DXZ() const {
107  };
108  virtual vector <string> _GetVariables2DYZ() const {
110  };
111 
112  virtual vector <string> _GetCoordinateVariables() const {
114  };
115 
116  virtual vector<long> _GetPeriodicBoundary() const {
118  };
119 
120  virtual vector<long> _GetGridPermutation() const {
122  };
123 
124  virtual double _GetTSUserTime(size_t ts) const {
126  };
127 
128  virtual void _GetTSUserTimeStamp(size_t ts, string &s) const {
130  };
131 
132  virtual int _VariableExists(
133  size_t ts,
134  const char *varname,
135  int reflevel = 0,
136  int lod = 0
137  ) const {
138  return (WaveletBlock3DRegionReader::VariableExists(ts,varname,reflevel));
139  };
140 
141 
142  virtual int _OpenVariableRead(
143  size_t timestep,
144  const char *varname,
145  int reflevel = 0,
146  int lod = 0
147  ) {
149  timestep, varname, reflevel)
150  );
151  };
152 
153  virtual void _GetValidRegion(
154  size_t min[3], size_t max[3], int reflevel
155  ) const {
157  min, max, reflevel)
158  );
159  };
160 
161  virtual const float *_GetDataRange() const {
163  }
164 
165 
166  virtual int _BlockReadRegion(
167  const size_t bmin[3], const size_t bmax[3],
168  float *region
169  ) {
171  bmin, bmax, region, false)
172  );
173  };
174 
175  virtual int _CloseVariable() {
177  };
178 
179 };
180 
181 };
182 
183 #endif // _DataMgrWB_h_
A sub-region reader for VDF files.
virtual void _GetBlockSize(size_t bs[3], int reflevel) const
Definition: DataMgrWB.h:58
virtual int _VariableExists(size_t ts, const char *varname, int reflevel=0, int lod=0) const
Definition: DataMgrWB.h:132
virtual void GetDim(size_t dim[3], int reflevel=0) const
virtual string _GetCoordSystemType() const
Definition: DataMgrWB.h:66
vector< string > GetVariables2DYZ() const
Definition: MetadataVDC.h:553
virtual vector< string > _GetVariables2DYZ() const
Definition: DataMgrWB.h:108
void GetTSUserTimeStamp(size_t ts, string &s) const
Definition: MetadataVDC.h:730
vector< long > GetPeriodicBoundary() const
Definition: MetadataVDC.h:601
virtual void _GetDim(size_t dim[3], int reflevel) const
Definition: DataMgrWB.h:54
#define VDF_API
Definition: common.h:61
A cache based data reader.
Definition: DataMgr.h:39
void GetValidRegion(size_t min[3], size_t max[3], int reflevel) const
virtual int _GetNumTransforms() const
Definition: DataMgrWB.h:62
virtual vector< string > _GetVariables3D() const
Definition: DataMgrWB.h:98
vector< double > GetTSXCoords(size_t ts) const
Definition: MetadataVDC.h:805
virtual void _GetTSUserTimeStamp(size_t ts, string &s) const
Definition: DataMgrWB.h:128
virtual vector< double > _GetExtents(size_t ts) const
Definition: DataMgrWB.h:74
virtual double _GetTSUserTime(size_t ts) const
Definition: DataMgrWB.h:124
virtual int OpenVariableRead(size_t timestep, const char *varname, int reflevel=0, int lod=0)
virtual const float * GetDataRange() const
A class for managing data set metadata.
Definition: MetadataVDC.h:92
virtual void _GetValidRegion(size_t min[3], size_t max[3], int reflevel) const
Definition: DataMgrWB.h:153
virtual int _CloseVariable()
Definition: DataMgrWB.h:175
virtual int GetNumTransforms() const
Definition: MetadataVDC.h:308
virtual const size_t * GetBlockSize() const
Definition: MetadataVDC.h:264
virtual vector< string > _GetVariables2DXY() const
Definition: DataMgrWB.h:102
virtual ~DataMgrWB()
Definition: DataMgrWB.h:46
virtual vector< long > _GetGridPermutation() const
Definition: DataMgrWB.h:120
virtual vector< double > _GetTSXCoords(size_t ts) const
Definition: DataMgrWB.h:78
virtual vector< string > _GetVariables2DXZ() const
Definition: DataMgrWB.h:105
vector< double > GetTSZCoords(size_t ts) const
Definition: MetadataVDC.h:819
virtual int _BlockReadRegion(const size_t bmin[3], const size_t bmax[3], float *region)
Definition: DataMgrWB.h:166
vector< double > GetTSYCoords(size_t ts) const
Definition: MetadataVDC.h:812
virtual long _GetNumTimeSteps() const
Definition: DataMgrWB.h:90
virtual vector< long > _GetPeriodicBoundary() const
Definition: DataMgrWB.h:116
virtual string _GetGridType() const
Definition: DataMgrWB.h:70
string GetCoordSystemType() const
Definition: MetadataVDC.h:406
double GetTSUserTime(size_t ts) const
Definition: MetadataVDC.h:720
virtual const float * _GetDataRange() const
Definition: DataMgrWB.h:161
vector< string > GetCoordinateVariables() const
Definition: MetadataVDC.h:506
virtual vector< double > _GetTSYCoords(size_t ts) const
Definition: DataMgrWB.h:82
virtual string _GetMapProjection() const
Definition: DataMgrWB.h:94
virtual vector< double > _GetTSZCoords(size_t ts) const
Definition: DataMgrWB.h:86
virtual string GetMapProjection() const
long GetNumTimeSteps() const
virtual vector< string > _GetCoordinateVariables() const
Definition: DataMgrWB.h:112
A cache based data reader.
Definition: DataMgrWB.h:31
vector< double > GetExtents(size_t ts=0) const
vector< string > GetVariables2DXY() const
Definition: MetadataVDC.h:543
virtual int _OpenVariableRead(size_t timestep, const char *varname, int reflevel=0, int lod=0)
Definition: DataMgrWB.h:142
vector< string > GetVariables3D() const
Definition: MetadataVDC.h:498
string GetGridType() const
Definition: MetadataVDC.h:377
virtual int VariableExists(size_t ts, const char *varname, int reflevel=0, int lod=0) const
vector< string > GetVariables2DXZ() const
Definition: MetadataVDC.h:548
virtual int BlockReadRegion(const size_t bmin[3], const size_t bmax[3], float *region, bool unblock=true)
vector< long > GetGridPermutation() const
Definition: MetadataVDC.h:662