Beast - Music Synthesizer and Composer  0.11.1+10.g2da35
sfitime.hh
Go to the documentation of this file.
1  // Licensed GNU LGPL v2.1 or later: http://www.gnu.org/licenses/lgpl.html
2 #ifndef __SFI_TIME_H__
3 #define __SFI_TIME_H__
4 
5 #include <sfi/sfivalues.hh>
6 
7 /* --- time (unix micro seconds) --- */
8 #define SFI_USEC_FACTOR ((SfiTime) 1000000) /* 64bit wide */
9 #define SFI_MIN_TIME (631152000 * SFI_USEC_FACTOR) /* 1990-01-01 00:00:00 UTC */
10 #define SFI_MAX_TIME (2147483647 * SFI_USEC_FACTOR) /* 2038-01-19 03:14:07 UTC */
11 
12 
13 /* --- functions --- */
14 SfiTime sfi_time_system (void); /* utc */
15 SfiTime sfi_time_to_utc (SfiTime ustime);
16 SfiTime sfi_time_from_utc (SfiTime ustime);
17 gchar* sfi_time_to_string (SfiTime ustime);
18 gchar* sfi_time_to_nice_string (SfiTime ustime,
19  const gchar *elements);
20 SfiTime sfi_time_from_string (const gchar *time_string);
21 SfiTime sfi_time_from_string_err (const gchar *time_string,
22  gchar **error_p);
23 
24 
25 /* --- internal --- */
26 void _sfi_init_time (void);
27 
28 
29 #endif /* __SFI_TIME_H__ */
30 
31 /* vim:set ts=8 sts=2 sw=2: */
SfiTime sfi_time_from_string_err(const gchar *time_string, gchar **error_p)
Definition: sfitime.cc:220
gchar * sfi_time_to_nice_string(SfiTime ustime, const gchar *elements)
Definition: sfitime.cc:164
gchar * sfi_time_to_string(SfiTime ustime)
Definition: sfitime.cc:127
SfiTime sfi_time_from_utc(SfiTime ustime)
Definition: sfitime.cc:113
SfiTime sfi_time_to_utc(SfiTime ustime)
Definition: sfitime.cc:99
SfiTime sfi_time_system(void)
Definition: sfitime.cc:78
SfiTime sfi_time_from_string(const gchar *time_string)
Definition: sfitime.cc:204