OPeNDAP Hyrax Back End Server (BES)  Updated for version 3.8.3
HDFSPArrayAddCVField.h
Go to the documentation of this file.
1 // This file is part of the hdf4 data handler for the OPeNDAP data server.
3 // It retrieves the missing fields for some special NASA HDF4 data products.
4 // The products include TRMML2_V6,TRMML3B_V6,CER_AVG,CER_ES4,CER_CDAY,CER_CGEO,CER_SRB,CER_SYN,CER_ZAVG,OBPGL2,OBPGL3
5 // To know more information about these products,check HDFSP.h.
6 // Some third-dimension coordinate variable values are not provided.
7 // What we do here is to provide natural number series(1,2,3, ...) for
8 // these missing values. It doesn't make sense to visualize or analyze
9 // with vertical cross-section. One can check the data level by level.
10 
11 // Authors: MuQun Yang <myang6@hdfgroup.org>
12 // Copyright (c) 2010-2012 The HDF Group
14 
15 #ifndef HDFSPARRAY_ADDCVFIELD_H
16 #define HDFSPARRAY_ADDCVFIELD_H
17 
18 #include "mfhdf.h"
19 #include "hdf.h"
20 
21 #include "Array.h"
22 #include "HDFSPEnumType.h"
23 using namespace libdap;
24 
25 class HDFSPArrayAddCVField:public Array
26 {
27  public:
28  HDFSPArrayAddCVField (int32 dtype, SPType sptype, const::string & fieldname, int tnumelm, const string & n = "", BaseType * v = 0):
29  Array (n, v),
30  dtype(dtype),
31  sptype(sptype),
32  name(fieldname),
33  tnumelm (tnumelm)
34  {
35  }
37  {
38  }
39 
40  // Standard way of DAP handlers to pass the coordinates of the subsetted region to the handlers
41  // Return the number of elements to read.
42  int format_constraint (int *cor, int *step, int *edg);
43 
44  BaseType *ptr_duplicate ()
45  {
46  return new HDFSPArrayAddCVField (*this);
47  }
48 
49  virtual bool read ();
50 
51  private:
52 
53 
55  int32 dtype;
56 
58  SPType sptype;
59 
61  std::string name;
62 
63  int tnumelm;
64  // TRMM version 7 nlayer values are from the document
65  void Obtain_trmm_v7_layer(int, vector<int>&,vector<int>&,vector<int>&);
66 
67  // TRMM version 7 nthrash values are from the document
68  void Obtain_trmml3s_v7_nthrash(int, vector<int>&,vector<int>&,vector<int>&);
69 
70 };
71 
72 
73 #endif
HDFSPArrayAddCVField(int32 dtype, SPType sptype, const ::string &fieldname, int tnumelm, const string &n="", BaseType *v=0)
static class NCMLUtil overview
SPType
Definition: HDFSPEnumType.h:4