WXP C++ Library Version 6.74.9
Loading...
Searching...
No Matches
MosUData.h
1#ifndef _WINC_MOSUDATA
2#define _WINC_MOSUDATA
3
4#include <WXP/Date.h>
5#include <WXP/EarthPoint.h>
6#include <WXP/String.h>
7
8namespace WXP {
9 class MosUData {
10 public:
11 const static int NumData = 13;
12 private:
13 char id[7]; /* Station identifier */
14 float lat; /* Latitude */
15 float lon; /* Longitude */
16 float elev; /* Elevation */
17 Date date; /* Initial time of data */
18
19 int model; /* The model used in the data */
20 int num; /* The number of forecasts */
21 int hour[NumData]; /* The hour offset */
22 float t[NumData][4]; /* The temperature */
23 float rhum[NumData][4]; /* The relative humidity */
24 float vert[NumData]; /* The 700 mb vert velocity */
25 float lift[NumData]; /* The lifted index */
26 float thick[NumData]; /* The 1000-500 mb thickness */
27 float dir[NumData]; /* The wind direction */
28 float spd[NumData]; /* The wind speed */
29 float psl[NumData]; /* The sea level pressure */
30 float prec[NumData]; /* The quantitative precipitation */
31
32 public:
33 enum Model { NONE, NGM, ETA, NAM };
34
35 MosUData();
36 int init();
37 int setId( const char *rid );
38 int setId( const char *rid, float rlat, float rlon );
39 const char *getId();
40 int getLoc( float &rlat, float &rlon );
41 int getLoc( EarthPoint &ept );
43 inline float getLat(){ return lat; };
44 inline float getLon(){ return lon; };
45 int setElev( float relev );
46 float getElev();
47 int getSeconds();
48
49 int setDate( Date &rdate );
50 int getDate( Date &rdate );
51 Date getDate();
52 int setModel( int val );
53 int getModel();
54 int setNum( int val );
55 int getNum();
56 int setHour( int ind, int val );
57 int getHour( int ind );
58 int getInd( float hr );
59 int setT( int ind, int type, float val );
60 float getT( int ind, int type );
61 int setRHum( int ind, int type, float val );
62 float getRHum( int ind, int type );
63 int setVert( int ind, float val );
64 float getVert( int ind );
65 int setLift( int ind, float val );
66 float getLift( int ind );
67 int setThick( int ind, float val );
68 float getThick( int ind );
69 int setDir( int ind, float val );
70 float getDir( int ind );
71 int setSpd( int ind, float val );
72 float getSpd( int ind );
73 int setSLPres( int ind, float val );
74 float getSLPres( int ind );
75 int setPrec( int ind, float val );
76 float getPrec( int ind );
77
78 int print();
79
80 friend class MosUFile;
81 friend class MosDataTool;
82 };
83}
84#endif
This class stores date and time information.
Definition Date.h:8
This class processes data from MosData class.
Definition MosDataTool.h:9
This class stores MOS data.
Definition MosUData.h:9
int setPrec(int ind, float val)
Definition MosUData.cc:411
int setDir(int ind, float val)
Definition MosUData.cc:348
int print()
Definition MosUData.cc:430
int init()
Definition MosUData.cc:30
float getT(int ind, int type)
Definition MosUData.cc:251
Date getDate()
Definition MosUData.cc:78
float getDir(int ind)
Definition MosUData.cc:359
int setElev(float relev)
Definition MosUData.cc:163
float getPrec(int ind)
Definition MosUData.cc:422
int getModel()
Definition MosUData.cc:95
float getSLPres(int ind)
Definition MosUData.cc:401
int setModel(int val)
Definition MosUData.cc:86
float getElev()
Definition MosUData.cc:172
int setSLPres(int ind, float val)
Definition MosUData.cc:390
MosUData()
Definition MosUData.cc:23
int getSeconds()
Definition MosUData.cc:180
int setRHum(int ind, int type, float val)
Definition MosUData.cc:262
int setVert(int ind, float val)
Definition MosUData.cc:285
int setNum(int val)
Definition MosUData.cc:188
int setSpd(int ind, float val)
Definition MosUData.cc:369
float getThick(int ind)
Definition MosUData.cc:338
const char * getId()
Definition MosUData.cc:125
int setDate(Date &rdate)
Definition MosUData.cc:60
int setT(int ind, int type, float val)
Definition MosUData.cc:238
float getVert(int ind)
Definition MosUData.cc:296
EarthPoint getLoc()
Definition MosUData.cc:153
int getNum()
Definition MosUData.cc:197
int setHour(int ind, int val)
Definition MosUData.cc:206
int setLift(int ind, float val)
Definition MosUData.cc:306
int getHour(int ind)
Definition MosUData.cc:217
int setId(const char *rid)
Definition MosUData.cc:103
float getSpd(int ind)
Definition MosUData.cc:380
float getRHum(int ind, int type)
Definition MosUData.cc:274
int setThick(int ind, float val)
Definition MosUData.cc:327
float getLift(int ind)
Definition MosUData.cc:317
This class reads MOS data files.
Definition MosUFile.h:10
All WXP classes fall under the WXP namespace.
Definition Angle.h:4
This struct defines earth point values (lat, lon, elev)
Definition EarthPoint.h:5