1
0
mirror of https://github.com/postgres/postgres.git synced 2025-07-07 00:36:50 +03:00

Remove hard-wired lists of timezone abbreviations in favor of providing

configuration files that can be altered by a DBA.  The australian_timezones
GUC setting disappears, replaced by a timezone_abbreviations setting (set this
to 'Australia' to get the effect of australian_timezones).  The list of zone
names defined by default has undergone a bit of cleanup, too.  Documentation
still needs some work --- in particular, should we fix Table B-4, or just get
rid of it?  Joachim Wieland, with some editorializing by moi.
This commit is contained in:
Tom Lane
2006-07-25 03:51:23 +00:00
parent 631ea61883
commit d8b5c95ca8
40 changed files with 2988 additions and 519 deletions

View File

@ -0,0 +1,35 @@
/*-------------------------------------------------------------------------
*
* tzparser.h
* Timezone offset file parsing definitions.
*
* Portions Copyright (c) 1996-2006, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* $PostgreSQL: pgsql/src/include/utils/tzparser.h,v 1.1 2006/07/25 03:51:22 tgl Exp $
*
*-------------------------------------------------------------------------
*/
#ifndef TZPARSER_H
#define TZPARSER_H
/*
* The result of parsing a timezone configuration file is an array of
* these structs, in order by abbrev. We export this because datetime.c
* needs it.
*/
typedef struct tzEntry
{
/* the actual data: TZ abbrev (downcased), offset, DST flag */
char *abbrev;
int offset; /* in seconds from UTC */
bool is_dst;
/* source information (for error messages) */
int lineno;
const char *filename;
} tzEntry;
extern bool load_tzoffsets(const char *filename, bool doit, int elevel);
#endif /* TZPARSER_H */