PostgreSQL Source Code
git master
|
Go to the source code of this file.
Macros | |
#define | indicator_set ind_type != NULL && ind_type->type != ECPGt_NO_INDICATOR |
Functions | |
struct ECPGstruct_member * | ECPGstruct_member_dup (struct ECPGstruct_member *rm) |
void | ECPGmake_struct_member (const char *name, struct ECPGtype *type, struct ECPGstruct_member **start) |
struct ECPGtype * | ECPGmake_simple_type (enum ECPGttype type, const char *size, int counter) |
struct ECPGtype * | ECPGmake_array_type (struct ECPGtype *type, const char *size) |
struct ECPGtype * | ECPGmake_struct_type (struct ECPGstruct_member *rm, enum ECPGttype type, char *type_name, char *struct_sizeof) |
static const char * | get_type (enum ECPGttype type) |
static void | ECPGdump_a_simple (FILE *o, const char *name, enum ECPGttype type, char *varcharsize, char *arrsize, const char *size, const char *prefix, int counter) |
static void | ECPGdump_a_struct (FILE *o, const char *name, const char *ind_name, char *arrsize, struct ECPGtype *type, struct ECPGtype *ind_type, const char *prefix, const char *ind_prefix) |
void | ECPGdump_a_type (FILE *o, const char *name, struct ECPGtype *type, const int brace_level, const char *ind_name, struct ECPGtype *ind_type, const int ind_brace_level, const char *prefix, const char *ind_prefix, char *arr_str_size, const char *struct_sizeof, const char *ind_struct_sizeof) |
void | ECPGfree_struct_member (struct ECPGstruct_member *rm) |
void | ECPGfree_type (struct ECPGtype *type) |
const char * | get_dtype (enum ECPGdtype type) |
Variables | |
static struct ECPGstruct_member | struct_no_indicator = {"no_indicator", &ecpg_no_indicator, NULL} |
#define indicator_set ind_type != NULL && ind_type->type != ECPGt_NO_INDICATOR |
|
static |
Definition at line 387 of file type.c.
References variable::arrsize, ecpg_type_name(), ECPGt_bytea, ECPGt_char, ECPGt_char_variable, ECPGt_const, ECPGt_date, ECPGt_descriptor, ECPGt_interval, ECPGt_NO_INDICATOR, ECPGt_numeric, ECPGt_sqlda, ECPGt_string, ECPGt_timestamp, ECPGt_unsigned_char, ECPGt_varchar, fprintf, free, get_type(), mm_alloc(), name, variable::offset, size, sprintf, type, and variable::varcharsize.
Referenced by ECPGdump_a_type().
|
static |
Definition at line 557 of file type.c.
References ecpg_no_indicator, ECPGdump_a_type(), ET_WARNING, free, ECPGtype::members, mm_alloc(), mmerror(), name, ECPGstruct_member::name, ECPGstruct_member::next, PARSE_ERROR, sprintf, struct_no_indicator, ECPGtype::struct_sizeof, type, ECPGstruct_member::type, and ECPGtype::u.
Referenced by ECPGdump_a_type().
void ECPGdump_a_type | ( | FILE * | o, |
const char * | name, | ||
struct ECPGtype * | type, | ||
const int | brace_level, | ||
const char * | ind_name, | ||
struct ECPGtype * | ind_type, | ||
const int | ind_brace_level, | ||
const char * | prefix, | ||
const char * | ind_prefix, | ||
char * | arr_str_size, | ||
const char * | struct_sizeof, | ||
const char * | ind_struct_sizeof | ||
) |
Definition at line 217 of file type.c.
References base_yyerror(), variable::brace_level, ECPGdump_a_simple(), ECPGdump_a_struct(), ECPGt_array, ECPGt_char_variable, ECPGt_const, ECPGt_descriptor, ECPGt_NO_INDICATOR, ECPGt_sqlda, ECPGt_struct, ECPGt_union, ET_ERROR, ET_WARNING, find_variable(), free, variable::ind_type, INDICATOR_NOT_ARRAY, INDICATOR_NOT_SIMPLE, INDICATOR_NOT_STRUCT, indicator_set, IS_SIMPLE_TYPE, mm_strdup(), mmerror(), mmfatal(), name, PARSE_ERROR, str, type, and variable::type.
Referenced by dump_variables(), ECPGdump_a_struct(), output_get_descr(), and output_set_descr().
void ECPGfree_struct_member | ( | struct ECPGstruct_member * | rm | ) |
Definition at line 617 of file type.c.
References free, ECPGstruct_member::name, ECPGstruct_member::next, and ECPGstruct_member::type.
Referenced by ECPGfree_type(), and main().
void ECPGfree_type | ( | struct ECPGtype * | type | ) |
Definition at line 631 of file type.c.
References base_yyerror(), ECPGfree_struct_member(), ECPGt_array, ECPGt_struct, ECPGt_union, ET_ERROR, free, IS_SIMPLE_TYPE, mmerror(), PARSE_ERROR, and type.
Referenced by remove_variables().
Definition at line 87 of file type.c.
References ECPGmake_simple_type(), ECPGt_array, ECPGtype::element, size, type, and ECPGtype::u.
Referenced by ECPGstruct_member_dup(), find_struct_member(), and find_variable().
Definition at line 72 of file type.c.
References ECPGtype::counter, ECPGtype::element, mm_alloc(), mm_strdup(), size, ECPGtype::size, ECPGtype::struct_sizeof, type, ECPGtype::type, ECPGtype::type_name, and ECPGtype::u.
Referenced by ECPGmake_array_type(), ECPGmake_struct_type(), ECPGstruct_member_dup(), find_struct_member(), and find_variable().
void ECPGmake_struct_member | ( | const char * | name, |
struct ECPGtype * | type, | ||
struct ECPGstruct_member ** | start | ||
) |
Definition at line 53 of file type.c.
References mm_alloc(), mm_strdup(), name, ECPGstruct_member::name, ECPGstruct_member::next, start, type, and ECPGstruct_member::type.
Referenced by ECPGstruct_member_dup().
struct ECPGtype* ECPGmake_struct_type | ( | struct ECPGstruct_member * | rm, |
enum ECPGttype | type, | ||
char * | type_name, | ||
char * | struct_sizeof | ||
) |
Definition at line 97 of file type.c.
References ECPGmake_simple_type(), ECPGstruct_member_dup(), ECPGtype::members, mm_strdup(), ECPGtype::struct_sizeof, type, ECPGtype::type_name, and ECPGtype::u.
Referenced by ECPGstruct_member_dup(), find_struct_member(), and find_variable().
struct ECPGstruct_member* ECPGstruct_member_dup | ( | struct ECPGstruct_member * | rm | ) |
Definition at line 13 of file type.c.
References ECPGtype::counter, ECPGmake_array_type(), ECPGmake_simple_type(), ECPGmake_struct_member(), ECPGmake_struct_type(), ECPGt_array, ECPGt_struct, ECPGt_union, ECPGtype::element, ECPGtype::members, ECPGstruct_member::name, ECPGstruct_member::next, ECPGtype::size, ECPGtype::struct_sizeof, type, ECPGstruct_member::type, ECPGtype::type, ECPGtype::type_name, and ECPGtype::u.
Referenced by ECPGmake_struct_type().
const char* get_dtype | ( | enum ECPGdtype | type | ) |
Definition at line 669 of file type.c.
References ECPGd_cardinality, ECPGd_count, ECPGd_data, ECPGd_di_code, ECPGd_di_precision, ECPGd_indicator, ECPGd_key_member, ECPGd_length, ECPGd_name, ECPGd_nullable, ECPGd_octet, ECPGd_precision, ECPGd_ret_length, ECPGd_ret_octet, ECPGd_scale, ECPGd_type, ET_ERROR, mmerror(), PARSE_ERROR, and type.
Referenced by output_get_descr(), and output_set_descr().
|
static |
Definition at line 109 of file type.c.
References ECPGt_bool, ECPGt_bytea, ECPGt_char, ECPGt_char_variable, ECPGt_const, ECPGt_date, ECPGt_decimal, ECPGt_descriptor, ECPGt_double, ECPGt_float, ECPGt_int, ECPGt_interval, ECPGt_long, ECPGt_long_long, ECPGt_NO_INDICATOR, ECPGt_numeric, ECPGt_short, ECPGt_sqlda, ECPGt_string, ECPGt_timestamp, ECPGt_unsigned_char, ECPGt_unsigned_int, ECPGt_unsigned_long, ECPGt_unsigned_long_long, ECPGt_unsigned_short, ECPGt_varchar, ET_ERROR, mmerror(), PARSE_ERROR, and type.
Referenced by ECPGdump_a_simple().
|
static |
Definition at line 1 of file type.c.
Referenced by ECPGdump_a_struct().