31 G_warning(
"Vect_write_line() %s",
_(
"for this format/level not supported"));
41 _(
"for this format/level not supported"));
48 _(
"for this format/level not supported"));
56 _(
"for this format/level not supported"));
60#if !defined HAVE_POSTGRES
63 G_fatal_error(
_(
"Requested format is not compiled in this version"));
70 G_fatal_error(
_(
"Requested format is not compiled in this version"));
78 G_fatal_error(
_(
"Requested format is not compiled in this version"));
87 G_fatal_error(
_(
"Requested format is not compiled in this version"));
137 {restore_dummy, restore_dummy, restore_dummy},
138 {restore_dummy, restore_dummy, restore_dummy}
141 {restore_dummy, restore_dummy, restore_dummy}
148static int check_map(
struct Map_info *);
173 G_debug(3,
"Vect_write_line(): name = %s, format = %d, level = %d",
179 offset = (*Vect_write_line_array[
Map->format][
Map->level])(
Map,
type,
183 G_warning(
_(
"Unable to write feature in vector map <%s>"),
216 "Vect_rewrite_line(): name = %s, format = %d, level = %d, "
227 " in vector map <%s>"),
250 G_debug(3,
"Vect_delete_line(): name = %s, line/offset = %" PRId64,
256 ret = (*Vect_delete_line_array[
Map->format][
Map->level])(
Map, line);
260 " from vector map <%s>"),
285 "Vect_restore_line(): name = %s, level = %d, offset = %" PRId64
293 (*Vect_restore_line_array[
Map->format][
Map->level])(
Map, offset, line);
297 " in vector map <%s>"),
311 G_warning(
_(
"Vector map <%s> is not opened in write mode"),
AMI_err name(char **stream_name)
void void void void G_fatal_error(const char *,...) __attribute__((format(printf
void G_warning(const char *,...) __attribute__((format(printf
int G_debug(int, const char *,...) __attribute__((format(printf
off_t V1_rewrite_line_ogr(struct Map_info *, off_t, int, const struct line_pnts *, const struct line_cats *)
Rewrites feature at the given offset on level 1 (OGR interface)
off_t V2_write_line_sfa(struct Map_info *, int, const struct line_pnts *, const struct line_cats *)
Writes feature on level 2 (OGR/PostGIS interface, pseudo-topological level)
int V1_delete_line_pg(struct Map_info *, off_t)
Deletes feature at the given offset (level 1)
off_t V1_write_line_nat(struct Map_info *, int, const struct line_pnts *, const struct line_cats *)
Writes feature to 'coor' file at level 1 (internal use only)
off_t V1_write_line_ogr(struct Map_info *, int, const struct line_pnts *, const struct line_cats *)
Writes feature on level 1 (OGR interface)
int V2_delete_line_pg(struct Map_info *, off_t)
Deletes feature on topological level (PostGIS interface)
off_t V2_write_line_pg(struct Map_info *, int, const struct line_pnts *, const struct line_cats *)
Writes feature on topological level (PostGIS interface)
const char * Vect_get_name(struct Map_info *)
Get name of vector map.
off_t V2_rewrite_line_sfa(struct Map_info *, off_t, int, const struct line_pnts *, const struct line_cats *)
Rewrites feature at the given offset on level 2 (OGR/PostGIS interface, pseudo-topological level)
off_t V2_write_line_nat(struct Map_info *, int, const struct line_pnts *, const struct line_cats *)
Writes feature to 'coor' file at topological level (internal use only)
int V2_delete_line_nat(struct Map_info *, off_t)
Deletes feature at topological level (internal use only)
int V1_restore_line_nat(struct Map_info *, off_t, off_t)
Restores feature at level 1 (internal use only)
int V1_delete_line_ogr(struct Map_info *, off_t)
Deletes feature at the given offset on level 1 (OGR interface)
off_t V2_rewrite_line_nat(struct Map_info *, off_t, int, const struct line_pnts *, const struct line_cats *)
Rewrites feature to 'coor' file at topological level (internal use only)
off_t V1_rewrite_line_nat(struct Map_info *, off_t, int, const struct line_pnts *, const struct line_cats *)
Rewrites feature to 'coor' file at level 1 (internal use only)
int V2_restore_line_nat(struct Map_info *, off_t, off_t)
Restores feature at topological level (internal use only)
int V1_delete_line_nat(struct Map_info *, off_t)
Deletes feature at level 1 (internal use only)
off_t V2_rewrite_line_pg(struct Map_info *, off_t, int, const struct line_pnts *, const struct line_cats *)
Rewrites feature at topological level (PostGIS interface, internal use only)
int V2_delete_line_sfa(struct Map_info *, off_t)
Deletes feature on level 2 (OGR/PostGIS interface)
off_t V1_write_line_pg(struct Map_info *, int, const struct line_pnts *, const struct line_cats *)
Writes feature on level 1 (PostGIS interface)
off_t V1_rewrite_line_pg(struct Map_info *, off_t, int, const struct line_pnts *, const struct line_cats *)
Rewrites feature at the given offset (level 1) (PostGIS interface, internal use only)
#define VECT_OPEN(Map)
Check if vector map is open.
#define GV_MODE_WRITE
Write vector map open mode.
#define GV_MODE_RW
Read-write vector map open mode.
#define G_UNUSED
A macro for an attribute, if attached to a variable, indicating that the variable is not used.
int type
Feature type constraint.
int format
Map format (native, ogr, postgis)
Feature geometry info - coordinates.
int Vect_delete_line(struct Map_info *Map, off_t line)
Delete existing feature (topological level required)
off_t Vect_write_line(struct Map_info *Map, int type, const struct line_pnts *points, const struct line_cats *cats)
Writes a new feature.
int Vect_restore_line(struct Map_info *Map, off_t offset, off_t line)
Restore previously deleted feature (topological level required)
off_t Vect_rewrite_line(struct Map_info *Map, off_t line, int type, const struct line_pnts *points, const struct line_cats *cats)
Rewrites existing feature (topological level required)