ToolMap
|
Public Member Functions | |
void | SetProject (PrjDefMemManage *prj) |
virtual bool | Open (const wxString &filename, bool bReadWrite=FALSE) |
Generic open code. | |
virtual tmRealRect | GetMinimalBoundingRectangle () |
virtual TM_GIS_SPATIAL_TYPES | GetSpatialType () |
Getting Data Spatial type. | |
virtual bool | SetSpatialFilter (tmRealRect filter, int type) |
Set a spatial filter for geometric data. | |
virtual wxRealPoint * | GetNextDataLine (int &nbvertex, long &oid, bool &isOver) |
virtual wxRealPoint * | GetNextDataPoint (long &oid, bool &isOver) |
OGRPoint * | GetNextDataPointWithAttrib (long &oid, wxArrayString &values) |
virtual OGRLineString * | GetNextDataLine (long &oid) |
virtual OGRPoint * | GetOGRNextDataPoint (long &oid) |
virtual OGRFeature * | GetFeatureByOID (long oid) |
Get the geometry for specified oid. | |
virtual long | AddGeometry (OGRGeometry *Geom, const long &oid, int layertype=wxNOT_FOUND) |
Add geometry into database. | |
virtual bool | UpdateGeometry (OGRGeometry *geom, const long &oid) |
Update the geometry for specified OID. | |
virtual OGRGeometryCollection * | GetGeometryColByOID (wxArrayLong *OIDs) |
Get all geometries passed as array. | |
virtual OGRGeometry * | GetNextGeometry (bool restart, long &oid) |
virtual wxString | GetMetaDataAsHtml () |
Get Metadata information well formated. | |
virtual wxString | GetDataSizeAsHtml (int iPrecision=2) |
Getting Database size. | |
virtual int | GetFieldsCount () |
virtual bool | GetFieldsName (wxArrayString &Fields, long oid=wxNOT_FOUND) |
virtual bool | GetFieldsValue (wxArrayString &values, long oid) |
virtual int | GetCount () |
Getting number of features. | |
virtual wxArrayLong * | SearchData (const tmRealRect &rect, int type) |
Search spatial data. | |
virtual wxArrayLong * | GetAllData () |
Get All OID back from the MySQL layer. | |
virtual wxArrayLong * | SearchIntersectingGeometry (OGRGeometry *intersectinggeom) |
Search data for intersection. | |
virtual bool | GetSnapCoord (const wxRealPoint &clickpt, double buffersize, wxArrayRealPoints &snapppts, int snaptype) |
Get snapping coordinate. | |
virtual bool | IsPointSnapped (const wxRealPoint &point, int snaptype, long excludeoid=wxNOT_FOUND) |
Public Member Functions inherited from tmGISDataVector | |
OGRLineString * | InsertVertex (OGRGeometry *pointbuffer, wxRealPoint ptclicked, OGRLineString *line, int &inseredvertex) |
Insert a vertex in a passed line. | |
OGRLineString * | InsertVertexMultiple (OGRLineString *line, OGRMultiPoint *vertex, const wxArrayInt &point_pos) |
Insert multiple vertex into line. | |
virtual bool | SetAttributeFilter (const wxString &query) |
virtual OGRFeature * | GetNextFeature () |
virtual bool | ResetReading () |
virtual int | GetNextDataPolygonInfo (long &oid) |
virtual wxRealPoint * | GetNextDataPolygon (int currentring, int &nbvertex) |
virtual bool | SplitGeometry (OGRGeometryCollection *gCol, const long &oid, wxArrayLong &AddedIds, int layertype) |
Save splitted geometry to file. | |
virtual void | CloseGeometry () |
virtual bool | DeleteFile (const wxString &layername) |
wxString | GetFieldsMetadata () |
Formating fields info into html string. | |
bool | CutLineAtVertex (long oid, const wxRealPoint &clickedpt, int searchRadius, int layertype) |
Cut line in two at specified point. | |
bool | CutLineGeometry (OGRLineString *line1, OGRLineString *line2, OGRMultiLineString &res1, OGRMultiLineString &res2) |
Cut two lines where they intesects. | |
bool | CutLineMultiple (OGRLineString *linetocut, OGRMultiLineString *cutlines, OGRMultiLineString &results) |
Cut one line with multiple line. | |
bool | LinesMerge (OGRMultiLineString *linetomerge, OGRGeometry **linemerged) |
Merge lines. | |
virtual int | IsRaster () |
Public Member Functions inherited from tmGISData | |
tmGISData () | |
Constructor. | |
~tmGISData () | |
Destructor. | |
int | GetDataType () |
void | SetCoordConvert (tmCoordConvert *coordconvert) |
tmCoordConvert * | GetCoordConvert () |
virtual bool | Close () |
wxString | GetShortFileName () |
wxString | GetFullFileName () |
virtual bool | CreateSpatialIndex (GDALProgressFunc progress, void *pfProgressData) |
Static Public Member Functions | |
static void | SetDataBaseHandle (DataBaseTM *db) |
static DataBaseTM * | GetDataBaseHandle () |
Static Public Member Functions inherited from tmGISDataVector | |
static void | InitGISDriversVector () |
static wxString | GetAllVectorGISFormatsWildcards () |
static tmGISDataVector * | CreateGISVectorBasedOnType (const int &gis_format_index) |
static tmGISDataVector * | CreateGISVectorBasedOnExt (const wxString &extension) |
static OGRGeometry * | CreateOGRGeometry (const tmRealRect &rect) |
Create a OGR geometry. | |
Static Public Member Functions inherited from tmGISData | |
static void | InitGISDrivers (bool bRaster=TRUE, bool bVector=TRUE) |
Init the GDAL / OGR driver. | |
static wxString | GetAllSupportedGISFormatsWildcards () |
Return all supported formats. | |
static wxArrayString | GetAllSupportedGISFormatsExtensions () |
Returning all extensions in an array string. | |
static tmGISData * | CreateGISBasedOnType (const int &gis_format_index) |
Create an object of the specified format. | |
static tmGISData * | CreateGISBasedOnExt (const wxString &extension) |
static tmGISData * | LoadLayer (tmLayerProperties *layerprop) |
Call this function for loading a layer. | |
static void | EnableLogging (bool enable=true) |
static bool | IsLoggingEnabled () |
Protected Member Functions | |
bool | CheckGeometryFields (const wxString &tablename) |
OGRGeometry * | CreateDataBaseGeometry (MYSQL_ROW &row, const tmArrayULong &row_lengths, int geometry_col=0) |
long | GetOid (MYSQL_ROW &row, const int &col) |
Get object ID from MYSQL row results. | |
virtual wxString | GetTableName (TOC_GENERIC_NAME type) |
Protected Member Functions inherited from tmGISDataVector | |
bool | CheckGEOSIntersection (GEOSGeom *rect, GEOSGeom *object) |
Compute real GEOS intersection (not bounding box) | |
bool | CheckGEOSCrosses (GEOSGeom *g1, GEOSGeom *g2) |
Check for crossing (not bounding box) | |
GEOSGeom | CreateGEOSGeometry (OGRGeometry *geom) |
Create a GEOS geometry. | |
GEOSGeom | CreateGEOSGeometry (const tmRealRect &rect) |
Create a GEOS geometry. | |
bool | GetVertexIntersection (OGRGeometry *geometry, OGRGeometry *buffer, wxArrayRealPoints &points) |
Search if a vertex intersect the passed geometry. | |
bool | GetBeginEndInterseciton (OGRGeometry *geometry, OGRGeometry *buffer, wxArrayRealPoints &points) |
Search if a Begin/End vertex intersect the passed geometry. | |
Protected Member Functions inherited from tmGISData | |
wxString | GetMinimalBoundingRectangleAsHtml (int iprecision=2) |
Get Minimal bounding rectangle as html. | |
Additional Inherited Members | |
Static Protected Member Functions inherited from tmGISDataVector | |
static OGRGeometry * | SafeCreateFromGEOS (GEOSGeom geom) |
Safe conversion function. | |
static OGRGeometry * | SafeBuffer (OGRGeometry *ogrgeom, int size) |
static OGRGeometry * | SafeIntersection (OGRGeometry *geom1, OGRGeometry *geom2) |
Compute intersection. | |
static OGRGeometry * | SafeUnion (OGRGeometry *union1, OGRGeometry *line) |
Compute Union. | |
static OGRGeometry * | CreateOGRGeometry (const wxRealPoint &pt) |
Protected Attributes inherited from tmGISData | |
int | m_ClassType |
|
virtual |
Add geometry into database.
Geom | The Geometry to Add |
oid | No oid may be specified for MySQL, it's auto-incremented |
layertype | One of the TOC_GENERIC_NAME |
Reimplemented from tmGISDataVector.
|
virtual |
|
virtual |
Getting number of features.
Reimplemented from tmGISDataVector.
|
virtual |
Getting Database size.
Return the size of the database
Reimplemented from tmGISData.
|
virtual |
Get the geometry for specified oid.
oid | The OID of the searched feature |
Reimplemented from tmGISDataVector.
|
virtual |
Reimplemented from tmGISDataVector.
|
virtual |
Reimplemented from tmGISDataVector.
|
virtual |
Reimplemented from tmGISDataVector.
|
virtual |
Get all geometries passed as array.
OIDs | List of all OIDs for getting geometries |
Reimplemented from tmGISDataVector.
|
virtual |
Get Metadata information well formated.
Reimplemented from tmGISData.
|
virtual |
Reimplemented from tmGISData.
|
virtual |
Reimplemented from tmGISDataVector.
|
virtual |
Reimplemented from tmGISDataVector.
|
virtual |
Reimplemented from tmGISDataVector.
|
protected |
Get object ID from MYSQL row results.
row | Adress of a row MySQL result |
col | The zero based index of the column in which are stored the OID |
|
virtual |
Get snapping coordinate.
Return, if found, the closest existing coordinate for snapping
clickpt | The real coordinate of the clicked point |
iBuffer | the size of the buffer in map unit |
snappt | the returned snapping coordinate if function return true |
snaptype | the type of snapping : tmSNAPPING_BEGIN_END or tmSNAPPING_VERTEX |
Reimplemented from tmGISData.
|
virtual |
Getting Data Spatial type.
Reimplemented from tmGISDataVector.
|
protectedvirtual |
Reimplemented from tmGISDataVector.
|
virtual |
Reimplemented from tmGISData.
|
virtual |
Generic open code.
Mainly init member values used by all GIS class
filename | path and name of the GIS data to open |
bReadWrite | Should we open the dataset for r/w operations ? |
Reimplemented from tmGISData.
|
virtual |
Search spatial data.
rect | Real rectangle for searching data |
type | Layertype see tmLayerProperties |
Reimplemented from tmGISData.
|
virtual |
Search data for intersection.
Search in all dataset for objects intersecting the passed geometry. First we specify a rectangle (for spatial filter) and then we search with GEOS inside the results
intersectinggeom | The geometry we search for intersection |
Reimplemented from tmGISDataVector.
|
virtual |
Set a spatial filter for geometric data.
This function sets a Geometric filter and ask the database for all data inside this filter
filter | the desired spatial filter |
type | one of the TOC_GENERIC_NAME, used to get the database table name |
Reimplemented from tmGISDataVector.
|
virtual |
Update the geometry for specified OID.
geom | The Geometry to Add |
oid | The OID we want to update |
Reimplemented from tmGISDataVector.