10#ifndef HDFEOS2ARRAY_SWATHGEOMULTIDIMMAPFIELD_H
11#define HDFEOS2ARRAY_SWATHGEOMULTIDIMMAPFIELD_H
13#include <libdap/Array.h>
18class HDFEOS2ArraySwathGeoMultiDimMapField:
public libdap::Array
21 HDFEOS2ArraySwathGeoMultiDimMapField (
int rank,
const std::string & filename,
22 const int swathfd,
const std::string & swathname,
23 const std::string & fieldname,
24 const int dim0size,
const int dim0offset,
const int dim0inc,
25 const int dim1size,
const int dim1offset,
const int dim1inc,
26 const std::string & n =
"",
27 libdap::BaseType * v =
nullptr):
32 swathname (swathname),
33 fieldname (fieldname),
35 dim0offset(dim0offset),
38 dim1offset(dim1offset),
41 ~ HDFEOS2ArraySwathGeoMultiDimMapField ()
override =
default;
44 int format_constraint (
int *cor,
int *step,
int *edg);
46 libdap::BaseType *ptr_duplicate ()
override
48 return new HDFEOS2ArraySwathGeoMultiDimMapField (*
this);
52 bool read ()
override;
65 std::string swathname;
68 std::string fieldname;
77 template <
class T >
int GetFieldValue (int32,
const std::string &,
const std::vector <int>&,
const std::vector <int>&,
const std::vector<int>&, std::vector < T > &, std::vector<int32>&);
80 template <
class T >
int _expand_dimmap_field (std::vector < T > *pvals, int32 rank, int32 dimsa[],
int dimindex, int32 ddimsize, int32 offset, int32 inc)
const;
83 template <
class T >
bool Field2DSubset (T * outlatlon,
const int majordim,
const int minordim, T * latlon,
const int32 * offset,
const int32 * count,
const int32 * step)
const;