GRASS GIS 7 Programmer's Manual  7.5.svn(2018)-r72095
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Plus_head Struct Reference

Basic topology-related info. More...

#include <dig_structs.h>

Collaboration diagram for Plus_head:

Data Fields

struct {
   struct Version_info   topo
 Version info for topology file. More...
 
   struct Version_info   spidx
 Version info for spatial index file. More...
 
   struct Version_info   cidx
 Version info for category index file. More...
 
version
 Backward compatibility version info. More...
 
int with_z
 2D/3D vector data More...
 
int spidx_with_z
 2D/3D spatial index More...
 
int off_t_size
 Offset size. More...
 
long head_size
 Topo header size. More...
 
long spidx_head_size
 Spatial index header size. More...
 
long cidx_head_size
 Category index header size. More...
 
int release_support
 Release memory occupied by support structures (topo, spatial, category) More...
 
struct Port_info port
 Portability information. More...
 
struct Port_info spidx_port
 Portability information for spatial index. More...
 
struct Port_info cidx_port
 Portability information for category index. More...
 
int mode
 Access mode. More...
 
int built
 Highest level of topology currently available. More...
 
struct bound_box box
 Bounding box of features. More...
 
struct P_node ** Node
 Array of nodes. More...
 
struct P_line ** Line
 Array of vector geometries. More...
 
struct P_area ** Area
 Array of areas. More...
 
struct P_isle ** Isle
 Array of isles. More...
 
plus_t n_plines
 Current number of points. More...
 
plus_t n_llines
 Current number of lines. More...
 
plus_t n_blines
 Current number of boundaries. More...
 
plus_t n_clines
 Current number of centroids. More...
 
plus_t n_flines
 Current number of faces. More...
 
plus_t n_klines
 Current number of kernels. More...
 
plus_t n_vfaces
 Current number of volume faces. More...
 
plus_t n_hfaces
 Current number of hole faces. More...
 
plus_t n_nodes
 Current number of topological features derived from vector geometries. More...
 
plus_t n_edges
 Current number of edges. More...
 
plus_t n_lines
 Current number of lines. More...
 
plus_t n_areas
 Current number of areas. More...
 
plus_t n_isles
 Current number of isles. More...
 
plus_t n_faces
 Current number of faces. More...
 
plus_t n_volumes
 Current number of volumes. More...
 
plus_t n_holes
 Current number of holes. More...
 
plus_t alloc_nodes
 Number of allocated nodes. More...
 
plus_t alloc_edges
 Number of allocated edges. More...
 
plus_t alloc_lines
 Number of allocated lines. More...
 
plus_t alloc_areas
 Number of allocated areas. More...
 
plus_t alloc_isles
 Number of allocated isles. More...
 
plus_t alloc_faces
 Number of allocated faces. More...
 
plus_t alloc_volumes
 Number of allocated volumes. More...
 
plus_t alloc_holes
 Number of allocated holes. More...
 
off_t Node_offset
 Offset of array of nodes in topo file. More...
 
off_t Edge_offset
 Offset of array of edges in topo file. More...
 
off_t Line_offset
 Offset of array of vector geometries in topo file. More...
 
off_t Area_offset
 Offset of array of areas in topo file. More...
 
off_t Isle_offset
 Offset of array of isles in topo file. More...
 
off_t Volume_offset
 Offset of array of volumes in topo file. More...
 
off_t Hole_offset
 Offset of array of holes in topo file. More...
 
int Spidx_built
 Spatial index built? More...
 
int Spidx_new
 Build new spatial index. More...
 
int Spidx_file
 Build new spatial index in file. More...
 
struct gvfile spidx_fp
 Spatial index file pointer. More...
 
off_t Node_spidx_offset
 Offset of nodes in sidx file. More...
 
off_t Line_spidx_offset
 Offset of lines in sidx file. More...
 
off_t Area_spidx_offset
 Offset of areas in sidx file. More...
 
off_t Isle_spidx_offset
 Offset of isles in sidx file. More...
 
off_t Face_spidx_offset
 Offset of faces in sidx file. More...
 
off_t Volume_spidx_offset
 Offset of volumes in sidx file. More...
 
off_t Hole_spidx_offset
 Offset of holes in sidx file. More...
 
struct RTreeNode_spidx
 Node spatial index. More...
 
struct RTreeLine_spidx
 Line spatial index. More...
 
struct RTreeArea_spidx
 Area spatial index. More...
 
struct RTreeIsle_spidx
 Isles spatial index. More...
 
struct RTreeFace_spidx
 Faces spatial index. More...
 
struct RTreeVolume_spidx
 Volumes spatial index. More...
 
struct RTreeHole_spidx
 Holes spatial index. More...
 
int update_cidx
 Update category index if vector is modified. More...
 
int n_cidx
 Number of category indexes (one for each field/layer) More...
 
int a_cidx
 Allocated space for category indexes. More...
 
struct Cat_indexcidx
 Array of category indexes. More...
 
int cidx_up_to_date
 Category index to be updated. More...
 
off_t coor_size
 Size of coor file. More...
 
long coor_mtime
 Time of last coor modification. More...
 
struct {
   int   do_uplist
 Indicates if the list of updated features is maintained. More...
 
   int *   uplines
 Array of updated lines. More...
 
   off_t *   uplines_offset
 Array of updated lines - offset. More...
 
   int   alloc_uplines
 Allocated array of lines. More...
 
   int   n_uplines
 Number of updated lines. More...
 
   int *   upnodes
 Array of updated nodes. More...
 
   int   alloc_upnodes
 Allocated array of nodes. More...
 
   int   n_upnodes
 number of updated nodes More...
 
uplist
 List of updated lines/nodes. More...
 

Detailed Description

Basic topology-related info.

Holds basic topology-related information about vector map

Important note: you should NOT store non-topological information in topological structures.

Definition at line 784 of file dig_structs.h.

Field Documentation

int Plus_head::a_cidx

Allocated space for category indexes.

Definition at line 1145 of file dig_structs.h.

Referenced by dig_cidx_add_cat(), dig_cidx_add_cat_sorted(), dig_cidx_free(), dig_cidx_init(), and dig_read_cidx_head().

plus_t Plus_head::alloc_areas

Number of allocated areas.

i.e. array size - 1

Definition at line 992 of file dig_structs.h.

Referenced by dig_add_area(), dig_alloc_areas(), and dig_free_plus_areas().

plus_t Plus_head::alloc_edges

Number of allocated edges.

i.e. array size - 1

Definition at line 980 of file dig_structs.h.

plus_t Plus_head::alloc_faces

Number of allocated faces.

i.e. array size - 1

Definition at line 1004 of file dig_structs.h.

plus_t Plus_head::alloc_holes

Number of allocated holes.

i.e. array size - 1

Definition at line 1016 of file dig_structs.h.

plus_t Plus_head::alloc_isles

Number of allocated isles.

i.e. array size - 1

Definition at line 998 of file dig_structs.h.

Referenced by dig_add_isle(), dig_alloc_isles(), and dig_free_plus_isles().

plus_t Plus_head::alloc_lines

Number of allocated lines.

i.e. array size - 1

Definition at line 986 of file dig_structs.h.

Referenced by dig_add_line(), dig_alloc_lines(), and dig_free_plus_lines().

plus_t Plus_head::alloc_nodes

Number of allocated nodes.

i.e. array size - 1

Definition at line 974 of file dig_structs.h.

Referenced by dig_add_node(), dig_alloc_nodes(), and dig_free_plus_nodes().

int Plus_head::alloc_uplines

Allocated array of lines.

Definition at line 1197 of file dig_structs.h.

Referenced by dig_line_add_updated().

int Plus_head::alloc_upnodes

Allocated array of nodes.

Definition at line 1209 of file dig_structs.h.

Referenced by dig_node_add_updated().

plus_t Plus_head::alloc_volumes

Number of allocated volumes.

i.e. array size - 1

Definition at line 1010 of file dig_structs.h.

off_t Plus_head::Area_offset

Offset of array of areas in topo file.

Definition at line 1033 of file dig_structs.h.

Referenced by dig_load_plus(), dig_Rd_Plus_head(), dig_Wr_Plus_head(), and dig_write_areas().

off_t Plus_head::Area_spidx_offset

Offset of areas in sidx file.

Definition at line 1083 of file dig_structs.h.

Referenced by dig_Rd_spidx(), dig_Rd_spidx_head(), dig_spidx_init(), dig_Wr_spidx(), and dig_Wr_spidx_head().

struct bound_box Plus_head::box

Bounding box of features.

Definition at line 877 of file dig_structs.h.

Referenced by dig_Rd_Plus_head(), dig_Wr_Plus_head(), V2_write_line_sfa(), Vect_build_nat(), Vect_get_map_box(), and Vect_topo_dump().

int Plus_head::built

Highest level of topology currently available.

  • GV_BUILD_NONE
  • GV_BUILD_BASE
  • GV_BUILD_AREAS
  • GV_BUILD_ATTACH_ISLES
  • GV_BUILD_CENTROIDS
  • GV_BUILD_ALL

Definition at line 873 of file dig_structs.h.

Referenced by dig_init_plus(), V2__delete_line_from_topo_nat(), V2_delete_line_sfa(), V2_write_line_sfa(), Vect__build_downgrade(), Vect__build_sfa(), Vect__open_old(), Vect_build_nat(), Vect_build_ogr(), Vect_build_partial(), Vect_build_pg(), Vect_close(), Vect_get_built(), and Vect_save_fidx().

struct Cat_index* Plus_head::cidx

Array of category indexes.

Definition at line 1149 of file dig_structs.h.

long Plus_head::cidx_head_size

Category index header size.

Definition at line 832 of file dig_structs.h.

Referenced by dig_read_cidx_head().

struct Port_info Plus_head::cidx_port

Portability information for category index.

Definition at line 853 of file dig_structs.h.

Referenced by dig_read_cidx(), dig_read_cidx_head(), dig_write_cidx(), dig_write_cidx_head(), and Vect_cidx_save().

int Plus_head::cidx_up_to_date

Category index to be updated.

Set to 1 when cidx is created and reset to 0 whenever any line is changed

Definition at line 1156 of file dig_structs.h.

Referenced by dig_cidx_free(), dig_cidx_init(), dig_read_cidx(), V2_delete_line_nat(), V2_delete_line_pg(), V2_delete_line_sfa(), V2_restore_line_nat(), V2_rewrite_line_nat(), V2_rewrite_line_pg(), V2_write_line_nat(), V2_write_line_sfa(), Vect__open_topo_pg(), and Vect_build_partial().

long Plus_head::coor_mtime

Time of last coor modification.

Definition at line 1165 of file dig_structs.h.

Referenced by Vect_close(), Vect_open_sidx(), and Vect_open_topo().

int Plus_head::do_uplist

Indicates if the list of updated features is maintained.

Definition at line 1177 of file dig_structs.h.

Referenced by dig_del_line(), V2__delete_line_from_topo_nat(), V2_rewrite_line_nat(), Vect__open_old(), and Vect_set_updated().

off_t Plus_head::Edge_offset

Offset of array of edges in topo file.

Definition at line 1025 of file dig_structs.h.

Referenced by dig_Rd_Plus_head(), and dig_Wr_Plus_head().

struct RTree* Plus_head::Face_spidx

Faces spatial index.

Definition at line 1120 of file dig_structs.h.

Referenced by dig_spidx_init().

off_t Plus_head::Face_spidx_offset

Offset of faces in sidx file.

Definition at line 1091 of file dig_structs.h.

Referenced by dig_Rd_spidx_head(), dig_spidx_init(), and dig_Wr_spidx_head().

long Plus_head::head_size

Topo header size.

Definition at line 824 of file dig_structs.h.

Referenced by dig_Rd_Plus_head().

off_t Plus_head::Hole_offset

Offset of array of holes in topo file.

Definition at line 1045 of file dig_structs.h.

Referenced by dig_Rd_Plus_head(), and dig_Wr_Plus_head().

struct RTree* Plus_head::Hole_spidx

Holes spatial index.

Definition at line 1128 of file dig_structs.h.

Referenced by dig_spidx_init().

off_t Plus_head::Hole_spidx_offset

Offset of holes in sidx file.

Definition at line 1099 of file dig_structs.h.

Referenced by dig_Rd_spidx_head(), dig_spidx_init(), and dig_Wr_spidx_head().

off_t Plus_head::Isle_offset

Offset of array of isles in topo file.

Definition at line 1037 of file dig_structs.h.

Referenced by dig_load_plus(), dig_Rd_Plus_head(), dig_Wr_Plus_head(), and dig_write_isles().

off_t Plus_head::Isle_spidx_offset

Offset of isles in sidx file.

Definition at line 1087 of file dig_structs.h.

Referenced by dig_Rd_spidx(), dig_Rd_spidx_head(), dig_spidx_init(), dig_Wr_spidx(), and dig_Wr_spidx_head().

off_t Plus_head::Line_offset

Offset of array of vector geometries in topo file.

Definition at line 1029 of file dig_structs.h.

Referenced by dig_load_plus(), dig_Rd_Plus_head(), dig_Wr_Plus_head(), and dig_write_lines().

off_t Plus_head::Line_spidx_offset

Offset of lines in sidx file.

Definition at line 1079 of file dig_structs.h.

Referenced by dig_Rd_spidx(), dig_Rd_spidx_head(), dig_spidx_init(), dig_Wr_spidx(), and dig_Wr_spidx_head().

int Plus_head::mode

Access mode.

  • GV_MODE_READ
  • GV_MODE_WRITE
  • GV_MODE_RW

Definition at line 861 of file dig_structs.h.

Referenced by Vect__open_old(), and Vect_build_partial().

plus_t Plus_head::n_blines
plus_t Plus_head::n_clines
plus_t Plus_head::n_edges

Current number of edges.

Definition at line 943 of file dig_structs.h.

Referenced by dig_Rd_Plus_head(), and dig_Wr_Plus_head().

plus_t Plus_head::n_faces

Current number of faces.

Definition at line 959 of file dig_structs.h.

plus_t Plus_head::n_hfaces

Current number of hole faces.

Definition at line 930 of file dig_structs.h.

plus_t Plus_head::n_holes

Current number of holes.

Definition at line 967 of file dig_structs.h.

Referenced by dig_Rd_Plus_head(), dig_Wr_Plus_head(), and Vect_get_num_holes().

plus_t Plus_head::n_nodes

Current number of topological features derived from vector geometries.

Current number of nodes

Definition at line 939 of file dig_structs.h.

Referenced by dig_add_node(), dig_free_plus_nodes(), dig_load_plus(), dig_Rd_Plus_head(), dig_which_node(), dig_Wr_Plus_head(), dig_write_nodes(), Vect_build_partial(), Vect_get_node_coor(), Vect_get_num_nodes(), Vect_node_alive(), and Vect_topo_dump().

plus_t Plus_head::n_plines
int Plus_head::n_uplines
int Plus_head::n_upnodes
plus_t Plus_head::n_vfaces

Current number of volume faces.

Definition at line 926 of file dig_structs.h.

plus_t Plus_head::n_volumes

Current number of volumes.

Definition at line 963 of file dig_structs.h.

Referenced by dig_Rd_Plus_head(), dig_Wr_Plus_head(), and Vect_get_num_volumes().

off_t Plus_head::Node_offset

Offset of array of nodes in topo file.

Definition at line 1021 of file dig_structs.h.

Referenced by dig_load_plus(), dig_Rd_Plus_head(), dig_Wr_Plus_head(), and dig_write_nodes().

off_t Plus_head::Node_spidx_offset

Offset of nodes in sidx file.

Definition at line 1075 of file dig_structs.h.

Referenced by dig_Rd_spidx(), dig_Rd_spidx_head(), dig_spidx_init(), dig_Wr_spidx(), and dig_Wr_spidx_head().

int Plus_head::off_t_size

Offset size.

Because Plus_head is available to all releveant functions

Definition at line 817 of file dig_structs.h.

Referenced by dig_Rd_P_line(), dig_Rd_Plus_head(), dig_Rd_spidx_head(), dig_read_cidx_head(), dig_Wr_P_line(), dig_Wr_Plus_head(), dig_Wr_spidx_head(), and dig_write_cidx_head().

struct Port_info Plus_head::port

Portability information.

Definition at line 845 of file dig_structs.h.

Referenced by dig_load_plus(), dig_Rd_Plus_head(), dig_Wr_Plus_head(), dig_write_plus_file(), and Vect_save_topo().

int Plus_head::release_support

Release memory occupied by support structures (topo, spatial, category)

Definition at line 838 of file dig_structs.h.

Referenced by Vect__init_head(), Vect_close(), and Vect_set_release_support().

struct Version_info Plus_head::spidx

Version info for spatial index file.

Definition at line 791 of file dig_structs.h.

Referenced by dig_Rd_spidx_head().

int Plus_head::Spidx_built

Spatial index built?

Set to 1 if spatial index is available

Definition at line 1053 of file dig_structs.h.

Referenced by dig_spidx_init(), Vect__init_head(), Vect_build_partial(), Vect_build_sidx(), Vect_close(), Vect_open_sidx(), Vect_save_sidx(), and Vect_sidx_dump().

int Plus_head::Spidx_file

Build new spatial index in file.

Set to 1 to build new indices in file

Definition at line 1065 of file dig_structs.h.

Referenced by dig_spidx_init(), and Vect_open_sidx().

struct gvfile Plus_head::spidx_fp

Spatial index file pointer.

Definition at line 1070 of file dig_structs.h.

Referenced by rtree_search(), Vect_close(), Vect_open_sidx(), and Vect_save_sidx().

long Plus_head::spidx_head_size

Spatial index header size.

Definition at line 828 of file dig_structs.h.

Referenced by dig_Rd_spidx_head(), and dig_Wr_spidx_head().

struct Port_info Plus_head::spidx_port

Portability information for spatial index.

Definition at line 849 of file dig_structs.h.

Referenced by dig_Rd_spidx(), dig_Rd_spidx_head(), dig_Wr_spidx(), dig_Wr_spidx_head(), rtree_search(), and Vect_save_sidx().

int Plus_head::spidx_with_z

2D/3D spatial index

  • WITH_Z
  • WITHOUT_Z

Definition at line 809 of file dig_structs.h.

Referenced by dig_Rd_spidx_head(), dig_spidx_init(), dig_Wr_spidx_head(), Vect__open_old(), and Vect_build_partial().

struct Version_info Plus_head::topo

Version info for topology file.

Definition at line 789 of file dig_structs.h.

Referenced by dig_Rd_Plus_head().

int* Plus_head::uplines

Array of updated lines.

List of lines and nodes updated (topo info for the line was changed) by last write/rewrite/delete operation. Lines/nodes in the list may be deleted (e.g. delete boundary: first added for delete area and then delete

Definition at line 1187 of file dig_structs.h.

Referenced by dig_line_add_updated(), and Vect_get_updated_line().

off_t* Plus_head::uplines_offset

Array of updated lines - offset.

Negative value for dead (deleted) lines - used by Vect_restore_line()

Definition at line 1193 of file dig_structs.h.

Referenced by dig_line_add_updated(), and Vect_get_updated_line_offset().

int* Plus_head::upnodes

Array of updated nodes.

Definition at line 1205 of file dig_structs.h.

Referenced by dig_node_add_updated(), and Vect_get_updated_node().

struct { ... } Plus_head::version

Backward compatibility version info.

Referenced by dig_Rd_Plus_head(), dig_Rd_spidx_head(), and dig_read_cidx_head().

off_t Plus_head::Volume_offset

Offset of array of volumes in topo file.

Definition at line 1041 of file dig_structs.h.

Referenced by dig_Rd_Plus_head(), and dig_Wr_Plus_head().

struct RTree* Plus_head::Volume_spidx

Volumes spatial index.

Definition at line 1124 of file dig_structs.h.

Referenced by dig_spidx_init().

off_t Plus_head::Volume_spidx_offset

Offset of volumes in sidx file.

Definition at line 1095 of file dig_structs.h.

Referenced by dig_Rd_spidx_head(), dig_spidx_init(), and dig_Wr_spidx_head().


The documentation for this struct was generated from the following file: