|
GRASS 8 Programmer's Manual 8.6.0dev(2026)-ddeab64dbf
|
Vector library - write vector feature - simple feature access (level 2) More...
#include <grass/vector.h>#include <grass/glocale.h>#include "local_proto.h"#include "pg_local_proto.h"
Go to the source code of this file.
Functions | |
| off_t | V2_write_line_sfa (struct Map_info *Map, int type, const struct line_pnts *points, const struct line_cats *cats) |
| Writes feature on level 2 (OGR/PostGIS interface, pseudo-topological level) | |
| off_t | V2_rewrite_line_sfa (struct Map_info *Map, off_t line, int type, const struct line_pnts *points, const struct line_cats *cats) |
| Rewrites feature at the given offset on level 2 (OGR/PostGIS interface, pseudo-topological level) | |
| int | V2_delete_line_sfa (struct Map_info *Map, off_t line) |
| Deletes feature on level 2 (OGR/PostGIS interface) | |
| off_t | V2__write_area_sfa (struct Map_info *Map, const struct line_pnts **points, int nparts, const struct line_cats *cats) |
| Writes area on topological level (Simple Features interface, internal use only) | |
Vector library - write vector feature - simple feature access (level 2)
Higher level functions for reading/writing/manipulating vectors.
See write_ogr.c (OGR interface) and write_pg.c (PostGIS interface) for implementation issues.
SFA version of V2__delete_area_cats_from_cidx_nat()
function to delete corresponding entry in fidx
SFA version of V2__add_area_cats_to_cidx_nat
SFA version of V2__add_line_to_topo_nat
(C) 2011-2012 by Martin Landa, and 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 write_sfa.c.
| off_t V2__write_area_sfa | ( | struct Map_info * | Map, |
| const struct line_pnts ** | points, | ||
| int | nparts, | ||
| const struct line_cats * | cats | ||
| ) |
Writes area on topological level (Simple Features interface, internal use only)
| Map | pointer to Map_info structure |
| points | feature geometry (exterior + interior rings) |
| nparts | number of parts including exterior ring |
| cats | feature categories |
Definition at line 276 of file write_sfa.c.
References _, G_fatal_error(), G_warning(), GV_FORMAT_OGR, GV_FORMAT_POSTGIS, V2__write_area_ogr(), and V2__write_area_pg().
Referenced by Vect__copy_areas().
Deletes feature on level 2 (OGR/PostGIS interface)
Note: Topology must be built at level >= GV_BUILD_BASE
| pointer | to Map_info structure |
| line | feature id to be deleted |
Definition at line 181 of file write_sfa.c.
References _, Plus_head::built, Plus_head::cidx_up_to_date, dig_cidx_del_cat(), dig_del_line(), FALSE, G_debug(), G_fatal_error(), G_warning(), GV_BOUNDARY, GV_BUILD_AREAS, GV_BUILD_BASE, GV_BUILD_CENTROIDS, GV_CENTROID, GV_FORMAT_POSTGIS, NULL, P_line::offset, P_line::type, Plus_head::update_cidx, V1_delete_line_ogr(), V1_delete_line_pg(), V2_read_line_sfa(), Vect_new_cats_struct(), Vect_new_line_struct(), line_pnts::x, line_pnts::y, and line_pnts::z.
Referenced by V2_delete_line_pg(), and V2_rewrite_line_sfa().
| off_t V2_rewrite_line_sfa | ( | struct Map_info * | Map, |
| off_t | line, | ||
| int | type, | ||
| const struct line_pnts * | points, | ||
| const struct line_cats * | cats | ||
| ) |
Rewrites feature at the given offset on level 2 (OGR/PostGIS interface, pseudo-topological level)
Note: Topology must be built at level >= GV_BUILD_BASE
| Map | pointer to Map_info structure |
| line | feature id to be rewritten |
| type | feature type (see V1_write_line_ogr() for supported types) |
| points | pointer to line_pnts structure (feature geometry) |
| cats | pointer to line_cats structure feature categories |
Definition at line 145 of file write_sfa.c.
References _, G_debug(), G_warning(), NULL, V2_delete_line_sfa(), V2_read_line_sfa(), and V2_write_line_sfa().
| off_t V2_write_line_sfa | ( | struct Map_info * | Map, |
| int | type, | ||
| const struct line_pnts * | points, | ||
| const struct line_cats * | cats | ||
| ) |
Writes feature on level 2 (OGR/PostGIS interface, pseudo-topological level)
| Map | pointer to Map_info structure |
| type | feature type (see V1_write_line_ogr() for list of supported types) |
| points | pointer to line_pnts structure (feature geometry) |
| cats | pointer to line_cats structure (feature categories) |
Definition at line 50 of file write_sfa.c.
References _, Plus_head::box, Plus_head::built, Plus_head::cidx_up_to_date, dig_add_line(), dig_cidx_add_cat(), dig_line_box(), FALSE, G_debug(), G_warning(), GV_BOUNDARY, GV_BUILD_BASE, GV_CENTROID, GV_FORMAT_POSTGIS, Plus_head::update_cidx, Plus_head::uplist, V1_write_line_ogr(), V1_write_line_pg(), Vect_append_point(), Vect_box_copy(), Vect_box_extend(), Vect_destroy_line_struct(), Vect_get_point_in_poly(), Vect_new_line_struct(), line_pnts::x, x, and line_pnts::y.
Referenced by V2_rewrite_line_sfa(), and V2_write_line_pg().