PostgreSQL Source Code
git master
|
#include "pgtypes_error.h"
Go to the source code of this file.
Data Structures | |
union | un_fmt_comb |
Macros | |
#define | PGTYPES_TYPE_NOTHING 0 |
#define | PGTYPES_TYPE_STRING_MALLOCED 1 |
#define | PGTYPES_TYPE_STRING_CONSTANT 2 |
#define | PGTYPES_TYPE_CHAR 3 |
#define | PGTYPES_TYPE_DOUBLE_NF 4 /* no fractional part */ |
#define | PGTYPES_TYPE_INT64 5 |
#define | PGTYPES_TYPE_UINT 6 |
#define | PGTYPES_TYPE_UINT_2_LZ 7 /* 2 digits, pad with leading zero */ |
#define | PGTYPES_TYPE_UINT_2_LS |
#define | PGTYPES_TYPE_UINT_3_LZ 9 |
#define | PGTYPES_TYPE_UINT_4_LZ 10 |
#define | PGTYPES_TYPE_UINT_LONG 11 |
#define | PGTYPES_FMT_NUM_MAX_DIGITS 40 |
Functions | |
int | pgtypes_fmt_replace (union un_fmt_comb replace_val, int replace_type, char **output, int *pstr_len) |
char * | pgtypes_alloc (long size) |
char * | pgtypes_strdup (const char *str) |
#define PGTYPES_FMT_NUM_MAX_DIGITS 40 |
Definition at line 23 of file pgtypeslib_extern.h.
#define PGTYPES_TYPE_CHAR 3 |
Definition at line 13 of file pgtypeslib_extern.h.
#define PGTYPES_TYPE_DOUBLE_NF 4 /* no fractional part */ |
Definition at line 14 of file pgtypeslib_extern.h.
#define PGTYPES_TYPE_INT64 5 |
Definition at line 15 of file pgtypeslib_extern.h.
#define PGTYPES_TYPE_NOTHING 0 |
Definition at line 10 of file pgtypeslib_extern.h.
#define PGTYPES_TYPE_STRING_CONSTANT 2 |
Definition at line 12 of file pgtypeslib_extern.h.
#define PGTYPES_TYPE_STRING_MALLOCED 1 |
Definition at line 11 of file pgtypeslib_extern.h.
#define PGTYPES_TYPE_UINT 6 |
Definition at line 16 of file pgtypeslib_extern.h.
#define PGTYPES_TYPE_UINT_2_LS |
Definition at line 18 of file pgtypeslib_extern.h.
#define PGTYPES_TYPE_UINT_2_LZ 7 /* 2 digits, pad with leading zero */ |
Definition at line 17 of file pgtypeslib_extern.h.
#define PGTYPES_TYPE_UINT_3_LZ 9 |
Definition at line 19 of file pgtypeslib_extern.h.
#define PGTYPES_TYPE_UINT_4_LZ 10 |
Definition at line 20 of file pgtypeslib_extern.h.
#define PGTYPES_TYPE_UINT_LONG 11 |
Definition at line 21 of file pgtypeslib_extern.h.
char* pgtypes_alloc | ( | long | size | ) |
Definition at line 10 of file common.c.
Referenced by get_str_from_var(), pgtypes_fmt_replace(), PGTYPESdate_defmt_asc(), PGTYPESdate_fmt_asc(), PGTYPESdate_new(), PGTYPESdecimal_new(), PGTYPESinterval_from_asc(), PGTYPESinterval_new(), PGTYPESnumeric_from_asc(), PGTYPESnumeric_new(), and PGTYPEStimestamp_defmt_scan().
int pgtypes_fmt_replace | ( | union un_fmt_comb | replace_val, |
int | replace_type, | ||
char ** | output, | ||
int * | pstr_len | ||
) |
Definition at line 30 of file common.c.
References un_fmt_comb::char_val, un_fmt_comb::double_val, free, i, INT64_FORMAT, un_fmt_comb::int64_val, output, pgtypes_alloc(), PGTYPES_FMT_NUM_MAX_DIGITS, PGTYPES_TYPE_CHAR, PGTYPES_TYPE_DOUBLE_NF, PGTYPES_TYPE_INT64, PGTYPES_TYPE_NOTHING, PGTYPES_TYPE_STRING_CONSTANT, PGTYPES_TYPE_STRING_MALLOCED, PGTYPES_TYPE_UINT, PGTYPES_TYPE_UINT_2_LS, PGTYPES_TYPE_UINT_2_LZ, PGTYPES_TYPE_UINT_3_LZ, PGTYPES_TYPE_UINT_4_LZ, snprintf, un_fmt_comb::str_val, and un_fmt_comb::uint_val.
Referenced by dttofmtasc_replace().
char* pgtypes_strdup | ( | const char * | str | ) |
Definition at line 20 of file common.c.
References str.
Referenced by pgtypes_defmt_scan(), PGTYPESdate_defmt_asc(), PGTYPESdate_to_asc(), PGTYPESinterval_to_asc(), PGTYPEStimestamp_defmt_asc(), and PGTYPEStimestamp_to_asc().