WXP C++ Library Version 6.74.9
Loading...
Searching...
No Matches
DateVal.h
1#ifndef _WINC_DATEVAL
2#define _WINC_DATEVAL
3
4namespace WXP {
5 struct DateVal {
6 int year;
7 int month;
8 int day;
9 int hour;
10 int min;
11 float sec;
13 static int num_day[13];
14 static int num_day_leap[13];
16 int init();
17 DateVal();
18 int validate();
19 long computeSecs();
20 int set( int ryear, int rmonth, int rday, int rhour, int rmin, float rsec );
22 inline int setYear( int val ){ year = val; return 1; };
24 inline int getYear(){ return year; };
26 inline int setMonth( int val ){ month = val; return 1; };
28 inline int getMonth(){ return month; };
30 inline int setDay( int val ){ day = val; return 1; };
32 inline int getDay(){ return day; };
34 inline int setHour( int val ){ hour = val; return 1; };
36 inline int getHour(){ return hour; };
38 inline int setMinute( int val ){ min = val; return 1; };
40 inline int getMinute(){ return min; };
42 inline int setSecond( float val ){ sec = val; return 1; };
44 inline float getSecond(){ return sec; };
45 int print();
46 };
47}
48#endif
49
All WXP classes fall under the WXP namespace.
Definition Angle.h:4
This struct defines basic date values.
Definition DateVal.h:5
int init()
Definition DateVal.cc:25
int getHour()
Definition DateVal.h:36
int setHour(int val)
Definition DateVal.h:34
DateVal()
Definition DateVal.cc:38
int year
Definition DateVal.h:6
int set(int ryear, int rmonth, int rday, int rhour, int rmin, float rsec)
Definition DateVal.cc:51
int print()
Definition DateVal.cc:157
float sec
Definition DateVal.h:11
int month
Definition DateVal.h:7
int setYear(int val)
Definition DateVal.h:22
int setSecond(float val)
Definition DateVal.h:42
int getMonth()
Definition DateVal.h:28
int getDay()
Definition DateVal.h:32
int min
Definition DateVal.h:10
int validate()
Definition DateVal.cc:65
long computeSecs()
Definition DateVal.cc:97
float getSecond()
Definition DateVal.h:44
static int num_day[13]
Definition DateVal.h:13
static int num_day_leap[13]
Definition DateVal.h:14
int day
Definition DateVal.h:8
int getMinute()
Definition DateVal.h:40
int hour
Definition DateVal.h:9
int setMinute(int val)
Definition DateVal.h:38
int getYear()
Definition DateVal.h:24
int setMonth(int val)
Definition DateVal.h:26
int setDay(int val)
Definition DateVal.h:30