PostGIS  2.4.9dev-r@@SVN_REVISION@@
shp2pgsql-core.c File Reference
#include "../postgis_config.h"
#include "shp2pgsql-core.h"
#include "../liblwgeom/liblwgeom.h"
#include "../liblwgeom/lwgeom_log.h"
Include dependency graph for shp2pgsql-core.c:

Go to the source code of this file.

Data Structures

struct  struct_point
 
struct  struct_ring
 

Macros

#define UTF8_GOOD_RESULT   0
 
#define UTF8_BAD_RESULT   1
 
#define UTF8_NO_RESULT   2
 

Typedefs

typedef struct struct_point Point
 
typedef struct struct_ring Ring
 

Functions

char * escape_copy_string (char *str)
 Escape input string suitable for COPY. More...
 
char * escape_insert_string (char *str)
 Escape input string suitable for INSERT. More...
 
int GeneratePointGeometry (SHPLOADERSTATE *state, SHPObject *obj, char **geometry, int force_multi)
 Generate an allocated geometry string for shapefile object obj using the state parameters if "force_multi" is true, single points will instead be created as multipoints with a single vertice. More...
 
int GenerateLineStringGeometry (SHPLOADERSTATE *state, SHPObject *obj, char **geometry)
 Generate an allocated geometry string for shapefile object obj using the state parameters. More...
 
int PIP (Point P, Point *V, int n)
 PIP(): crossing number test for a point in a polygon input: P = a point, V[] = vertex points of a polygon V[n+1] with V[n]=V[0]. More...
 
int FindPolygons (SHPObject *obj, Ring ***Out)
 
void ReleasePolygons (Ring **polys, int npolys)
 
int GeneratePolygonGeometry (SHPLOADERSTATE *state, SHPObject *obj, char **geometry)
 Generate an allocated geometry string for shapefile object obj using the state parameters. More...
 
static int utf8 (const char *fromcode, char *inputbuf, char **outputbuf)
 
void strtolower (char *s)
 
void set_loader_config_defaults (SHPLOADERCONFIG *config)
 
SHPLOADERSTATEShpLoaderCreate (SHPLOADERCONFIG *config)
 
int ShpLoaderOpenShape (SHPLOADERSTATE *state)
 
int ShpLoaderGetSQLHeader (SHPLOADERSTATE *state, char **strheader)
 
int ShpLoaderGetSQLCopyStatement (SHPLOADERSTATE *state, char **strheader)
 
int ShpLoaderGetRecordCount (SHPLOADERSTATE *state)
 
int ShpLoaderGenerateSQLRowStatement (SHPLOADERSTATE *state, int item, char **strrecord)
 
int ShpLoaderGetSQLFooter (SHPLOADERSTATE *state, char **strfooter)
 
void ShpLoaderDestroy (SHPLOADERSTATE *state)