Products Support Documentation Download
rdmdatetimetypes.h
Go to the documentation of this file.
1 /* ----------------------------------------------------------------------------
2  * Raima Database Manager
3  *
4  * Copyright (c) 2010 Raima Inc., All rights reserved.
5  *
6  * Use of this software, whether in source code format, or in executable,
7  * binary object code form, is governed by the Raima LICENSE which
8  * is fully described in the LICENSE.TXT file, included within this
9  * distribution of files.
10  * ----------------------------------------------------------------------------
11  */
12 
17 #if !defined(RDMDATETIMETYPES_H_INCLUDED_)
18 #define RDMDATETIMETYPES_H_INCLUDED_
19 
20 #include "psptypes.h"
21 
23 #define RDM_DATE_MAX RDM_UINT32_MAX
24 
25 #define RDM_TIME_MAX ((((((23 * 60) + 59) * 60) + 59) * 10000) + 9999)
26 
28 #define MAX_TIME_PREC 10000
29 
31 #define RDM_DEF_DATE_FORMAT RDM_YYYYMMDD
32 
33 #define RDM_DEF_DATE_SEP '-'
34 
35 #define RDM_DEF_TIME_FORMAT RDM_HHMMSSFFFF
36 
37 typedef char RDM_DATE_SEPARATOR;
38 
41 typedef struct
42 {
43  int32_t year;
44  uint16_t month;
45  uint16_t day;
46 } RDM_DATE_T;
47 
50 typedef struct
51 {
52  uint16_t hour;
53  uint16_t minute;
54  uint16_t second;
55  uint16_t fraction;
56 } RDM_TIME_T;
57 
60 typedef struct
61 {
62  int32_t year;
63  uint16_t month;
64  uint16_t day;
65  uint16_t hour;
66  uint16_t minute;
67  uint16_t second;
68  uint16_t fraction;
70 
71 #if 0
72 
74 typedef struct
75 {
76  int32_t year;
77  uint16_t month;
78  uint16_t day;
79  int16_t tz;
80 } RDM_DATETZ_T;
81 #endif
82 
85 typedef struct
86 {
87  uint16_t hour;
88  uint16_t minute;
89  uint16_t second;
90  uint16_t fraction;
91  int16_t tz;
92 } RDM_TIMETZ_T;
93 
96 typedef struct
97 {
98  int32_t year;
99  uint16_t month;
100  uint16_t day;
101  uint16_t hour;
102  uint16_t minute;
103  uint16_t second;
104  uint16_t fraction;
105  int16_t tz;
107 
110 typedef uint32_t RDM_PACKED_DATE_T;
111 
114 typedef uint32_t RDM_PACKED_TIME_T;
115 
118 typedef struct
119 {
123 
126 typedef struct
127 {
129  int16_t tz;
131 
134 typedef struct
135 {
138  int16_t tz;
140 
142 typedef enum
143 {
144  /* GEN_RDM_DATE_FORMAT_BEGIN */
148  /* GEN_RDM_DATE_FORMAT_END */
150 
151 /* The comments need to be on one line as we parse this file to generate RsqlEnums.cs */
153 typedef enum
154 {
155  /* GEN_RDM_TIME_FORMAT_BEGIN */
156  RDM_HH = 1,
163  /* GEN_RDM_TIME_FORMAT_END */
165 
166 #endif /* RDMDATETIMETYPES_H_INCLUDED_ */
RDM_PACKED_DATE_T date
uint16_t fraction
uint16_t second
Header for the Platform Support Package - Platform dependent types.
The RDM Date data structure.
The RDM Timestamp data structure.
RDM_DATE_FORMAT
RDM Date format codes.
uint16_t day
uint32_t RDM_PACKED_TIME_T
The RDM packed Time data structure.
RDM_PACKED_TIME_T time
char RDM_DATE_SEPARATOR
uint16_t month
The RDM packed Timestamp with time zone data structure.
uint16_t fraction
uint16_t minute
uint16_t hour
The RDM packed Time with time zone data structure.
The RDM Time data structure.
The RDM Time w/ timezone data structure.
uint32_t RDM_PACKED_DATE_T
The RDM packed Date data structure.
The RDM packed Timestamp data structure.
RDM_PACKED_TIME_T time
The RDM Timestamp data structure.
RDM_TIME_FORMAT
RDM time format codes.