bes Updated for version 3.21.1
The Backend Server (BES) is the lower two tiers of the Hyrax data server
HDF5GMCFSpecialCVArray.h
Go to the documentation of this file.
1// This file is part of the hdf5_handler implementing for the CF-compliant
2// Copyright (c) 2011-2023 The HDF Group, Inc. and OPeNDAP, Inc.
3//
4// This is free software; you can redistribute it and/or modify it under the
5// terms of the GNU Lesser General Public License as published by the Free
6// Software Foundation; either version 2.1 of the License, or (at your
7// option) any later version.
8//
9// This software is distributed in the hope that it will be useful, but
10// WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
11// or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
12// License for more details.
13//
14// You should have received a copy of the GNU Lesser General Public
15// License along with this library; if not, write to the Free Software
16// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
17//
18// You can contact OPeNDAP, Inc. at PO Box 112, Saunderstown, RI. 02874-0112.
19// You can contact The HDF Group, Inc. at 410 E University Ave,
20// Suite 200, Champaign, IL 61820
21
31
32#ifndef _HDF5GMCFSpecialCVARRAY_H
33#define _HDF5GMCFSpecialCVARRAY_H
34
35// STL includes
36#include <string>
37#include <vector>
38
39#include "HDF5CF.h"
40#include "HDF5BaseArray.h"
41
42
43class HDF5GMCFSpecialCVArray: public HDF5BaseArray {
44public:
45 HDF5GMCFSpecialCVArray(H5DataType h5_dtype, int64_t h5_tnumelm, const std::string &varfullpath, H5GCFProduct h5_product_type,
46 const std::string & n = "", libdap::BaseType * v = nullptr) :
47 HDF5BaseArray(n, v), dtype(h5_dtype), tnumelm(h5_tnumelm), varname(varfullpath), product_type(h5_product_type)
48 {
49 }
50
51 ~ HDF5GMCFSpecialCVArray() override = default;
52 libdap::BaseType *ptr_duplicate() override;
53 bool read() override;
54
55private:
56 H5DataType dtype;
57 int64_t tnumelm;
58 std::string varname;
59 H5GCFProduct product_type;
60 CVType cvartype = CV_UNSUPPORTED;
61
62 // GPM version 3.0 nlayer values are from the document https://storm.pps.eosdis.nasa.gov/storm/filespec.GPM.V1.pdf
63 void obtain_gpm_l3_layer(int64_t, const std::vector<int64_t>&, const std::vector<int64_t>&, const std::vector<int64_t>& );
64
65 // GPM version 4.0 nlayer values are from the document
66 // http://www.eorc.jaxa.jp/GPM/doc/product/format/en/03.%20GPM_DPR_L2_L3%20Product%20Format%20Documentation_E.pdf
67 void obtain_gpm_l3_layer2(int64_t, const std::vector<int64_t>&, const std::vector<int64_t>&, const std::vector<int64_t>&);
68
69 void obtain_gpm_l3_nalt_hgt(int64_t, const std::vector<int64_t>&, const std::vector<int64_t>&, const std::vector<int64_t>&);
70#if 0
71 void obtain_gpm_l3_nalt(int64_t, const std::vector<int64_t>&, const std::vector<int64_t>&, const std::vector<int64_t>&);
72#endif
73 void read_data_NOT_from_mem_cache(bool add_cache, void*buf) override;
74
75};
76
77#endif // _HDF5GMCFSpecialCVARRAY_H
78
A helper class that aims to reduce code redundence for different special CF derived array class For e...
This class specifies the core engineering of mapping HDF5 to DAP by following CF.