• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /* Copyright (C) 2007-2008 The Android Open Source Project
2 **
3 ** This software is licensed under the terms of the GNU General Public
4 ** License version 2, as published by the Free Software Foundation, and
5 ** may be copied, distributed, and modified under those terms.
6 **
7 ** This program is distributed in the hope that it will be useful,
8 ** but WITHOUT ANY WARRANTY; without even the implied warranty of
9 ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
10 ** GNU General Public License for more details.
11 */
12 #ifndef _ANDROID_UTILS_TIMEZONE_H
13 #define _ANDROID_UTILS_TIMEZONE_H
14 
15 /* try to set the default host timezone, returns 0 on success, or -1 if
16  * 'tzname' is not in zoneinfo format (e.g. Area/Location)
17  */
18 extern int  timezone_set( const char*  tzname );
19 
20 /* append the current host "zoneinfo" timezone name to a given buffer. note
21  * that this is something like "America/Los_Angeles", and not the human-friendly "PST"
22  * this is required by the Android emulated system...
23  *
24  * the implementation of this function is really tricky and is OS-dependent
25  * on Unix systems, it needs to cater to the TZ environment variable, uhhh
26  *
27  * if TZ is defined to something like "CET" or "PST", this will return the name "Unknown/Unknown"
28  */
29 extern char*  bufprint_zoneinfo_timezone( char*  buffer, char*  end );
30 
31 #endif /* _ANDROID_UTILS_TIMEZONE_H */
32