All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
le_clock.h
Go to the documentation of this file.
1 
80 //--------------------------------------------------------------------------------------------------
89 #ifndef LEGATO_CLK_INCLUDE_GUARD
90 #define LEGATO_CLK_INCLUDE_GUARD
91 
92 //--------------------------------------------------------------------------------------------------
96 //--------------------------------------------------------------------------------------------------
97 typedef struct
98 {
99  time_t sec;
100  long usec;
101 } le_clk_Time_t;
102 
103 
104 //--------------------------------------------------------------------------------------------------
111 //--------------------------------------------------------------------------------------------------
112 #define LE_CLK_STRING_FORMAT_DATE_TIME "%c"
113 #define LE_CLK_STRING_FORMAT_DATE "%x"
115 #define LE_CLK_STRING_FORMAT_TIME "%X"
117 // @}
119 
120 
121 //--------------------------------------------------------------------------------------------------
131 //--------------------------------------------------------------------------------------------------
133 
134 
135 //--------------------------------------------------------------------------------------------------
145 //--------------------------------------------------------------------------------------------------
147 
148 
149 //--------------------------------------------------------------------------------------------------
156 //--------------------------------------------------------------------------------------------------
158 (
159  le_clk_Time_t timeA,
160  le_clk_Time_t timeB
161 );
162 
163 
164 //--------------------------------------------------------------------------------------------------
172 //--------------------------------------------------------------------------------------------------
174 (
175  le_clk_Time_t timeA,
176  le_clk_Time_t timeB
177 );
178 
179 
180 //--------------------------------------------------------------------------------------------------
187 //--------------------------------------------------------------------------------------------------
189 (
190  le_clk_Time_t timeA,
191  le_clk_Time_t timeB
192 );
193 
194 
195 //--------------------------------------------------------------------------------------------------
202 //--------------------------------------------------------------------------------------------------
204 (
205  le_clk_Time_t timeA,
206  int scaleFactor
207 );
208 
209 
210 //--------------------------------------------------------------------------------------------------
226 //--------------------------------------------------------------------------------------------------
228 (
229  const char* formatSpecStrPtr,
230  char* destStrPtr,
232  size_t destSize,
233  size_t* numBytesPtr
234 
237 );
238 
239 
240 //--------------------------------------------------------------------------------------------------
256 //--------------------------------------------------------------------------------------------------
258 (
259  const char* formatSpecStrPtr,
260  char* destStrPtr,
262  size_t destSize,
263  size_t* numBytesPtr
264 );
267 
268 
269 //--------------------------------------------------------------------------------------------------
286 //--------------------------------------------------------------------------------------------------
288 (
289  le_clk_Time_t time,
290  const char* formatSpecStrPtr,
291  char* destStrPtr,
293  size_t destSize,
294  size_t* numBytesPtr
295 
298 );
299 
300 
301 //--------------------------------------------------------------------------------------------------
317 //--------------------------------------------------------------------------------------------------
319 (
320  le_clk_Time_t time,
321  const char* formatSpecStrPtr,
322  char* destStrPtr,
324  size_t destSize,
325  size_t* numBytesPtr
326 
329 );
330 
331 #endif // LEGATO_CLK_INCLUDE_GUARD
332 
le_result_t le_clk_GetLocalDateTimeString(const char *formatSpecStrPtr, char *destStrPtr, size_t destSize, size_t *numBytesPtr)
bool le_clk_GreaterThan(le_clk_Time_t timeA, le_clk_Time_t timeB)
le_result_t
Definition: le_basics.h:34
le_result_t le_clk_GetUTCDateTimeString(const char *formatSpecStrPtr, char *destStrPtr, size_t destSize, size_t *numBytesPtr)
long usec
microseconds
Definition: le_clock.h:100
time_t sec
seconds
Definition: le_clock.h:99
le_clk_Time_t le_clk_Sub(le_clk_Time_t timeA, le_clk_Time_t timeB)
le_clk_Time_t le_clk_GetAbsoluteTime(void)
le_result_t le_clk_ConvertToUTCString(le_clk_Time_t time, const char *formatSpecStrPtr, char *destStrPtr, size_t destSize, size_t *numBytesPtr)
Definition: le_clock.h:97
le_clk_Time_t le_clk_Multiply(le_clk_Time_t timeA, int scaleFactor)
le_result_t le_clk_ConvertToLocalTimeString(le_clk_Time_t time, const char *formatSpecStrPtr, char *destStrPtr, size_t destSize, size_t *numBytesPtr)
le_clk_Time_t le_clk_Add(le_clk_Time_t timeA, le_clk_Time_t timeB)
le_clk_Time_t le_clk_GetRelativeTime(void)