GRASS GIS 7 Programmer's Manual
7.9.dev(2021)-e5379bbd7
|
GIS Library - Argument parsing functions (standard options) More...
Go to the source code of this file.
Functions | |
struct Option * | G_define_standard_option (int opt) |
Create standardised Option structure. More... | |
struct Flag * | G_define_standard_flag (int flag) |
Create standardised Flag structure. More... | |
GIS Library - Argument parsing functions (standard options)
(C) 2001-2019 by the GRASS Development Team
This program is free software under the GNU General Public License (>=v2). Read the file COPYING that comes with GRASS for details.
Definition in file parser_standard_options.c.
struct Flag* G_define_standard_flag | ( | int | flag | ) |
Create standardised Flag structure.
This function will create a standardised Flag structure defined by parameter flag. A list of valid parameters below. It allocates memory for the Flag structure and returns a pointer to this memory.
If an invalid parameter was specified a empty Flag structure will be returned (not NULL).
flag | type of Flag struct to create specified by STD_FLG enum. |
Definition at line 953 of file parser_standard_options.c.
References _, Flag::description, G_define_flag(), G_FLG_V_TABLE, G_FLG_V_TOPO, Flag::key, and Flag::label.
struct Option* G_define_standard_option | ( | int | opt | ) |
Create standardised Option structure.
This function will create a standardised Option structure defined by parameter opt.
Valid parameters are defined by the STD_OPT enum in the file gis.h. A list of valid parameter values sorted to groups is below.
This function allocates memory for the Option structure and returns a pointer to this memory.
If an invalid parameter was specified a empty Option structure will be returned (not NULL).
Values also need to be added to general/g.parser/standard_option.c
opt | type of Option struct to create specified by STD_OPT enum |
Definition at line 138 of file parser_standard_options.c.
References _, Option::answer, DEFAULT_FG_COLOR, Option::description, Option::descriptions, G_asprintf(), G_color_rules_description_type(), G_color_rules_options(), G_define_option(), G_getenv_nofatal(), G_OPT_C, G_OPT_CN, G_OPT_DB_COLUMN, G_OPT_DB_COLUMNS, G_OPT_DB_DATABASE, G_OPT_DB_DRIVER, G_OPT_DB_KEYCOLUMN, G_OPT_DB_SCHEMA, G_OPT_DB_SQL, G_OPT_DB_TABLE, G_OPT_DB_WHERE, G_OPT_F_BIN_INPUT, G_OPT_F_INPUT, G_OPT_F_OUTPUT, G_OPT_F_SEP, G_OPT_I_GROUP, G_OPT_I_SUBGROUP, G_OPT_M_COLR, G_OPT_M_COORDS, G_OPT_M_DATATYPE, G_OPT_M_DBASE, G_OPT_M_DIR, G_OPT_M_LOCATION, G_OPT_M_MAPSET, G_OPT_M_NULL_VALUE, G_OPT_M_REGION, G_OPT_M_UNITS, G_OPT_MAP_INPUT, G_OPT_MAP_INPUTS, G_OPT_MAP_TYPE, G_OPT_MEMORYMB, G_OPT_R3_COMPRESSION, G_OPT_R3_INPUT, G_OPT_R3_INPUTS, G_OPT_R3_MAP, G_OPT_R3_MAPS, G_OPT_R3_OUTPUT, G_OPT_R3_PRECISION, G_OPT_R3_TILE_DIMENSION, G_OPT_R3_TYPE, G_OPT_R_BASE, G_OPT_R_BASENAME_INPUT, G_OPT_R_BASENAME_OUTPUT, G_OPT_R_COVER, G_OPT_R_ELEV, G_OPT_R_ELEVS, G_OPT_R_INPUT, G_OPT_R_INPUTS, G_OPT_R_INTERP_TYPE, G_OPT_R_MAP, G_OPT_R_MAPS, G_OPT_R_OUTPUT, G_OPT_R_OUTPUTS, G_OPT_R_TYPE, G_OPT_STDS_INPUT, G_OPT_STDS_INPUTS, G_OPT_STDS_OUTPUT, G_OPT_STDS_TYPE, G_OPT_STR3DS_INPUT, G_OPT_STR3DS_INPUTS, G_OPT_STR3DS_OUTPUT, G_OPT_STRDS_INPUT, G_OPT_STRDS_INPUTS, G_OPT_STRDS_OUTPUT, G_OPT_STRDS_OUTPUTS, G_OPT_STVDS_INPUT, G_OPT_STVDS_INPUTS, G_OPT_STVDS_OUTPUT, G_OPT_T_SAMPLE, G_OPT_T_TYPE, G_OPT_T_WHERE, G_OPT_V3_TYPE, G_OPT_V_CAT, G_OPT_V_CATS, G_OPT_V_FIELD, G_OPT_V_FIELD_ALL, G_OPT_V_ID, G_OPT_V_IDS, G_OPT_V_INPUT, G_OPT_V_INPUTS, G_OPT_V_MAP, G_OPT_V_MAPS, G_OPT_V_OUTPUT, G_OPT_V_TYPE, G_store(), Option::gisprompt, GV_KEY_COLUMN, Option::key, Option::key_desc, Option::label, Option::multiple, NO, Option::options, Option::required, Option::type, TYPE_DOUBLE, TYPE_INTEGER, TYPE_STRING, and YES.