bes  Updated for version 3.20.6
HDFCFStrField.h
1 // This file is part of the hdf4 data handler for the OPeNDAP data server.
3 // It retrieves the HDF4 DFNT_CHAR >1D array and then send to DAP as a DAP string array for the CF option.
4 // Authors: MuQun Yang <myang6@hdfgroup.org> Eunsoo Seo
5 // Copyright (c) 2010-2012 The HDF Group
7 
8 #ifndef HDFCFSTR_FIELD_H
9 #define HDFCFSTR_FIELD_H
10 
11 #include "Array.h"
12 #include "HDFCFUtil.h"
13 
14 
15 class HDFCFStrField:public libdap::Array
16 {
17  public:
18  HDFCFStrField (int rank,
19  const std::string & filename,
20  bool is_vdata,
21  const int h4fd,
22  int32 fieldref,
23  int32 fieldorder,
24  const std::string & fieldname,
25  const std::string & n = "",
26  libdap::BaseType * v = 0):
27  Array (n, v),
28  rank (rank),
29  filename(filename),
30  is_vdata(is_vdata),
31  h4fd(h4fd),
32  fieldref(fieldref),
33  fieldorder(fieldorder),
34  fieldname(fieldname)
35  {
36  }
37  virtual ~ HDFCFStrField ()
38  {
39  }
40 
41  // Standard way to pass the coordinates of the subsetted region from the client to the handlers
42  int format_constraint (int *cor, int *step, int *edg);
43 
44  BaseType *ptr_duplicate ()
45  {
46  return new HDFCFStrField (*this);
47  }
48 
49  // Read the data.
50  virtual bool read ();
51 
52  private:
53 
54  // Field array rank
55  int rank;
56 
57  // file name
58  std::string filename;
59 
60  bool is_vdata;
61 
62  int h4fd;
63 
64  int32 fieldref;
65 
66  int32 fieldorder;
67 
68  // field name
69  std::string fieldname;
70 
71 };
72 
73 
74 #endif
HDFCFStrField
Definition: HDFCFStrField.h:15