WXP C++ Library Version 6.74.6
Loading...
Searching...
No Matches
SfcCdfFile.h
1#ifndef _WINC_SFCCDFFILE
2#define _WINC_SFCCDFFILE
3
4#include <WXP/NetCdfFile.h>
5#include <WXP/Date.h>
6#include <WXP/SfcData.h>
7
8namespace WXP {
9 class SfcCdfFile {
10 int type;
11 int ver;
12 int access;
13 long pos;
14 int cnt;
15 int num;
16 NetCdfFile cdf;
17 Date date;
18 bool opened;
19 /* variable ids */
20 int id_id; /* Station ID id */
21 int time_id; /* Obervation time id */
22 int lat_id; /* Sttion latitude id */
23 int lon_id; /* Station longitude id */
24 int elev_id; /* Station elevation id */
25 int t_id; /* Station temperature id */
26 int td_id; /* Station dewpoint id */
27 int psl_id; /* Sea level pressure id */
28 int altim_id; /* Altimeter setting id */
29 int spd_id; /* Wind speed id */
30 int dir_id; /* Wind direction id */
31 int zcl_id; /* Cloud base id */
32 int cc_id; /* Cloud coverage id */
33 int vis_id; /* Visibility id */
34 int region_id; /* Region id */
35 int wx_id; /* Station weather id */
36 int cld_id; /* Cloud type id */
37 int ptend_t_id; /* Pressure tendency type id */
38 int ptend_id; /* Pressure tendency id */
39 int precip_id; /* Precipitation id */
40 int r_precip_id; /* Precipitation ref time id */
41 int snow_id; /* Snow cover id */
42 int tmax_id; /* Max temperature id */
43 int tmin6_id; /* Min temperature id */
44 int tmax6_id; /* Max temperature id */
45 int tmin_id; /* Min temperature id */
46 int sun_id; /* Sunshine id */
47 int remark_id; /* Remark id */
48 int gust_id; /* Wind gust id */
49 int sst_id; /* SST id */
50 int wav_per_id; /* Wave period id */
51 int wav_hgt_id; /* Wave height id */
52 int intdata_id; /* Station integer data id */
53 int intname_id; /* Integer data names id */
54 int intunit_id; /* Integer data units id */
55 int fltdata_id; /* Station floating point data id */
56 int fltname_id; /* Floating point data names id */
57 int fltunit_id; /* Floating point data units id */
58 long remark_len; /* Length of remark section */
59 long num_station; /* Number of stations in netCDF file (current
60 length of unlimited dimension) */
61 float missing_f; /* Missing float value - netCDF global attr */
62 long missing_i; /* Missing int value - netCDF global attr */
63 char missing_c; /* Missing char value - netCDF global attr */
64
65 public:
66 SfcCdfFile( );
67 SfcCdfFile( const char *filename );
68 SfcCdfFile( const char *filename, int access );
69 ~SfcCdfFile( );
70 bool isOpen();
71 int open( const char *filename, int access );
72 int rewind( );
73 int close( );
74 int setDate( Date &rdate );
75 int getDate( Date &rdate );
76 int read( SfcData &data );
77 int write( SfcData &data );
78
79 static int checkType( const char *filename );
80 };
81}
82#endif
This class stores date and time information.
Definition: Date.h:8
This class is an access layer to netCDF files.
Definition: NetCdfFile.h:11
This class reads in surface data from a netCDF file.
Definition: SfcCdfFile.h:9
~SfcCdfFile()
Definition: SfcCdfFile.cc:372
SfcCdfFile()
Definition: SfcCdfFile.cc:44
int open(const char *filename, int access)
Definition: SfcCdfFile.cc:70
int rewind()
Definition: SfcCdfFile.cc:350
int getDate(Date &rdate)
Definition: SfcCdfFile.cc:389
int setDate(Date &rdate)
Definition: SfcCdfFile.cc:380
static int checkType(const char *filename)
Definition: SfcCdfFile.cc:31
int close()
Definition: SfcCdfFile.cc:361
int read(SfcData &data)
Definition: SfcCdfFile.cc:398
This class stores surface data.
Definition: SfcData.h:12
All WXP classes fall under the WXP namespace.
Definition: Angle.h:4