Defines | |
| #define | INFO_NUMPARTS 0 |
| #define | INFO_NUMPOINTS 1 |
| #define | INFO_XVERTEX 2 |
| #define | INFO_YVERTEX 3 |
Functions | |
| int MITAB_STDCALL | mitab_c_getlibversion () |
| Returns the version of the library. | |
| int MITAB_STDCALL | mitab_c_getlasterrorno () |
| Fetch the last error number. | |
| const char *MITAB_STDCALL | mitab_c_getlasterrormsg () |
| Get the last error message. | |
| int MITAB_STDCALL | mitab_c_getlasterrormsg_vb (char *errormsg, int l) |
| Get the last error message (VB Version). | |
| mitab_handle MITAB_STDCALL | mitab_c_open (const char *pszFilename) |
| Open an existing .TAB or .MIF dataset for read access. | |
| void MITAB_STDCALL | mitab_c_close (mitab_handle handle) |
| Close a dataset previously opened using mitab_c_open() or created using mitab_c_create(). | |
| mitab_handle MITAB_STDCALL | mitab_c_create (const char *filename, const char *mif_or_tab, const char *mif_projection, double north, double south, double east, double west) |
| Create a new .TAB or .MIF dataset. | |
| int MITAB_STDCALL | mitab_c_set_quick_spatial_index_mode (mitab_handle dataset) |
| Select "quick spatial index mode". | |
| int MITAB_STDCALL | mitab_c_add_field (mitab_handle dataset, const char *field_name, int field_type, int width, int precision, int indexed, int unique) |
| Add a new field to the dataset's schema. | |
| void MITAB_STDCALL | mitab_c_destroy_feature (mitab_feature feature) |
| Destroy a mitab_feature object and release all memory associated with it. | |
| int MITAB_STDCALL | mitab_c_next_feature_id (mitab_handle handle, int last_feature_id) |
| Iterator to get the next valid feature id when reading a dataset opened with mitab_c_open(). | |
| mitab_feature MITAB_STDCALL | mitab_c_read_feature (mitab_handle handle, int feature_id) |
| Read a mitab_feature object from the file. | |
| int MITAB_STDCALL | mitab_c_write_feature (mitab_handle handle, mitab_feature feature) |
| Write a new feature to a dataset. | |
| mitab_feature MITAB_STDCALL | mitab_c_create_feature (mitab_handle handle, int feature_type) |
| Create a new mitab_feature object to be written to a dataset created using mitab_c_create(). | |
| void MITAB_STDCALL | mitab_c_set_field (mitab_feature feature, int field_index, const char *field_value) |
| Set the value of specified field in a feature object. | |
| void MITAB_STDCALL | mitab_c_set_points (mitab_feature feature, int part, int vertex_count, double *x, double *y) |
| Set the feature's coordinates. | |
| void MITAB_STDCALL | mitab_c_set_arc (mitab_feature feature, double center_x, double center_y, double x_radius, double y_radius, double start_angle, double end_angle) |
| Set an arc or ellipse feature parameters. | |
| void MITAB_STDCALL | mitab_c_set_text (mitab_feature feature, const char *text) |
| Set the text string on a TABFC_Text object. | |
| const char *MITAB_STDCALL | mitab_c_get_text (mitab_feature feature) |
| Get the text string on a TABFC_Text object. | |
| int MITAB_STDCALL | mitab_c_get_text_vb (mitab_feature feature, char *text, int l) |
| Get the text string on a TABFC_Text object (VB Version). | |
| void MITAB_STDCALL | mitab_c_set_text_display (mitab_feature feature, double angle, double height, double width, int fg_color, int bg_color, int justification, int spacing, int linetype) |
| Set a TABFC_Text object's display properties. | |
| double MITAB_STDCALL | mitab_c_get_text_angle (mitab_feature feature) |
| Fetch a TABFC_Text object's angle property. | |
| double MITAB_STDCALL | mitab_c_get_text_height (mitab_feature feature) |
| Fetch a TABFC_Text object's MBR height property. | |
| double MITAB_STDCALL | mitab_c_get_text_width (mitab_feature feature) |
| Fetch a TABFC_Text object's MBR width property. | |
| int MITAB_STDCALL | mitab_c_get_text_fgcolor (mitab_feature feature) |
| Fetch a TABFC_Text object's foreground color property. | |
| int MITAB_STDCALL | mitab_c_get_text_bgcolor (mitab_feature feature) |
| Fetch a TABFC_Text object's background color property. | |
| int MITAB_STDCALL | mitab_c_get_text_justification (mitab_feature feature) |
| Fetch a TABFC_Text object's justification property. | |
| int MITAB_STDCALL | mitab_c_get_text_spacing (mitab_feature feature) |
| Fetch a TABFC_Text object's spacing property. | |
| int MITAB_STDCALL | mitab_c_get_text_linetype (mitab_feature feature) |
| Fetch a TABFC_Text object's linetype property. | |
| void MITAB_STDCALL | mitab_c_set_font (mitab_feature feature, const char *fontname) |
| Set the font name in a a TABFC_Text or TABFC_FontPoint object, or set the symbol name in a TABFC_CustomPoint. | |
| const char *MITAB_STDCALL | mitab_c_get_font (mitab_feature feature) |
| Get the font name from a TABFC_Text or TABFC_FontPoint object, or the symbol name from a TABFC_CustomPoint. | |
| int MITAB_STDCALL | mitab_c_get_font_vb (mitab_feature feature, char *font, int l) |
| Get the font name from a TABFC_Text or TABFC_FontPoint object, or the symbol name from a TABFC_CustomPoint. | |
| void MITAB_STDCALL | mitab_c_set_brush (mitab_feature feature, int fg_color, int bg_color, int pattern, int transparent) |
| Set an object's brush properties. | |
| int MITAB_STDCALL | mitab_c_get_brush_fgcolor (mitab_feature feature) |
| Get an object's brush foreground color property. | |
| int MITAB_STDCALL | mitab_c_get_brush_bgcolor (mitab_feature feature) |
| Get an object's brush background color property. | |
| int MITAB_STDCALL | mitab_c_get_brush_pattern (mitab_feature feature) |
| Get an object's brush pattern property. | |
| int MITAB_STDCALL | mitab_c_get_brush_transparent (mitab_feature feature) |
| Get an object's brush transparency property. | |
| void MITAB_STDCALL | mitab_c_set_pen (mitab_feature feature, int width, int pattern, int color) |
| Set an object's pen properties. | |
| int MITAB_STDCALL | mitab_c_get_pen_color (mitab_feature feature) |
| Get an object's pen color property. | |
| int MITAB_STDCALL | mitab_c_get_pen_width (mitab_feature feature) |
| Get an object's pen width property. | |
| int MITAB_STDCALL | mitab_c_get_pen_pattern (mitab_feature feature) |
| Get an object's pen pattern property. | |
| void MITAB_STDCALL | mitab_c_set_symbol (mitab_feature feature, int symbol_no, int symbol_size, int symbol_color) |
| Set an object's symbol properties. | |
| void MITAB_STDCALL | mitab_c_set_symbol_angle (mitab_feature feature, double symbol_angle) |
| Set the point symbol's angle. | |
| int MITAB_STDCALL | mitab_c_get_symbol_color (mitab_feature feature) |
| Get an object's symbol color property. | |
| int MITAB_STDCALL | mitab_c_get_symbol_no (mitab_feature feature) |
| Get an object's symbol number property. | |
| int MITAB_STDCALL | mitab_c_get_symbol_size (mitab_feature feature) |
| Get an object's symbol size property. | |
| double MITAB_STDCALL | mitab_c_get_symbol_angle (mitab_feature feature) |
| Get an font point object's angle property. | |
| int MITAB_STDCALL | mitab_c_get_type (mitab_feature feature) |
| Return a mitab_feature's object type. | |
| int MITAB_STDCALL | mitab_c_get_parts (mitab_feature feature) |
| Return the number of parts (rings or polyline segments) in an object. | |
| int MITAB_DLL MITAB_STDCALL | mitab_c_is_interior_ring (mitab_feature feature, int requestedringindex) |
| Return a false if te ring is the first of a polygon. | |
| int MITAB_STDCALL | mitab_c_get_vertex_count (mitab_feature feature, int part) |
| Return the number of points in a part of a mitab_feature object. | |
| double MITAB_STDCALL | mitab_c_get_vertex_x (mitab_feature feature, int part, int vertex) |
| Return the X coordinate of a point in a part of a mitab_feature object. | |
| double MITAB_STDCALL | mitab_c_get_vertex_y (mitab_feature feature, int part, int vertex) |
| Return the Y coordinate of a point in a part of a mitab_feature object. | |
| int MITAB_STDCALL | mitab_c_get_field_count (mitab_handle handle) |
| Return the number of attribute fields in a dataset's schema. | |
| int MITAB_STDCALL | mitab_c_get_feature_count (mitab_handle handle) |
| Return the number of features in a dataset. | |
| int MITAB_STDCALL | mitab_c_get_field_type (mitab_handle handle, int field) |
| Return the type of an attribute field in a dataset's schema. | |
| const char *MITAB_STDCALL | mitab_c_get_field_name (mitab_handle handle, int field) |
| Return the name of an attribute field in a dataset's schema. | |
| int MITAB_STDCALL | mitab_c_get_field_name_vb (mitab_handle handle, int field, char *name, int l) |
| Return the name of an attribute field in a dataset's schema (VB version). | |
| int MITAB_STDCALL | mitab_c_get_field_width (mitab_handle handle, int field) |
| Return the width of an attribute field in a dataset's schema. | |
| int MITAB_STDCALL | mitab_c_get_field_precision (mitab_handle handle, int field) |
| Return the precision of an attribute field in a dataset's schema. | |
| int MITAB_STDCALL | mitab_c_is_field_indexed (mitab_handle handle, int field) |
| Test whether specified field in a dataset's schema is indexed or not. | |
| int MITAB_STDCALL | mitab_c_is_field_unique (mitab_handle handle, int field) |
| For indexed fields only, test whether the specified indexed field in a dataset's schema has the unique flag set. | |
| const char *MITAB_STDCALL | mitab_c_get_field_as_string (mitab_feature feature, int field) |
| Fetch an attribute field value in a mitab_feature as a string. | |
| int MITAB_STDCALL | mitab_c_get_field_as_string_vb (mitab_feature feature, int field, char *value, int l) |
| Fetch an attribute field value in a mitab_feature as a string (VB Version). | |
| double MITAB_STDCALL | mitab_c_get_field_as_double (mitab_feature feature, int field) |
| Fetch an attribute field value in a mitab_feature as a double. | |
| mitab_projinfo MITAB_STDCALL | mitab_c_get_projinfo (mitab_handle dataset) |
| Get the projinfo handle from an opened dataset. | |
| int MITAB_STDCALL | mitab_c_set_projinfo (mitab_handle dataset, mitab_projinfo projinfo) |
| Set the projinfo on a newly created dataset. | |
| const char *MITAB_STDCALL | mitab_c_get_mif_coordsys (mitab_handle dataset) |
| Get the MIF CoordSys string from an opened dataset. | |
| const char *MITAB_STDCALL | mitab_c_get_extended_mif_coordsys (mitab_handle dataset) |
| Get the MIF CoordSys string from an opened dataset including the affine transformation parameters if available. | |
| void MITAB_STDCALL | mitab_c_get_projection_info (mitab_projinfo projInfo, int *nProjId, int *nEllipsoidId, int *nUnitsId, double *adProjParams) |
| void MITAB_STDCALL | mitab_c_set_projection_info (mitab_projinfo projInfo, int nProjId, int nEllipsoidId, int nUnitsId, double *adProjParams) |
| void MITAB_STDCALL | mitab_c_get_datum_info (mitab_projinfo projInfo, double *dDatumShiftX, double *dDatumShiftY, double *dDatumShiftZ, double *adDatumParams) |
| void MITAB_STDCALL | mitab_c_set_datum_info (mitab_projinfo projInfo, double dDatumShiftX, double dDatumShiftY, double dDatumShiftZ, double *adDatumParams) |
| int MITAB_STDCALL | mitab_c_get_affine_params (mitab_projinfo projInfo, int *nAffineUnits, double *adAffineParams) |
| void MITAB_STDCALL | mitab_c_set_affine_params (mitab_projinfo projInfo, int nAffineUnits, double *adAffineParams) |
| int MITAB_STDCALL | mitab_c_get_extended_mif_coordsys_vb (mitab_handle dataset, char *coordsys, int l) |
| Get the MIF CoordSys string from an opened dataset including the affine transformation parameters if available. | |
| int MITAB_STDCALL | mitab_c_get_mif_coordsys_vb (mitab_handle dataset, char *coordsys, int l) |
| Get the MIF CoordSys string from an opened dataset (VB Version). | |
| int MITAB_STDCALL | mitab_c_load_coordsys_table (const char *filename) |
| Load a Coordsys bounds lookup table from an external file. | |
| mitab_feature MITAB_STDCALL | mitab_c_get_collection_region_ref (mitab_feature feature) |
| Returns a reference to the region component of a collection. | |
| mitab_feature MITAB_STDCALL | mitab_c_get_collection_polyline_ref (mitab_feature feature) |
| Returns a reference to the polyline component of a collection. | |
| mitab_feature MITAB_STDCALL | mitab_c_get_collection_multipoint_ref (mitab_feature feature) |
| Returns a reference to the multipoint component of a collection. | |
| int MITAB_STDCALL | mitab_c_set_collection_region (mitab_feature feature, mitab_feature region, int make_copy) |
| Set or update the region component of a collection. | |
| int MITAB_STDCALL | mitab_c_set_collection_polyline (mitab_feature feature, mitab_feature polyline, int make_copy) |
| Set or update the polyline component of a collection. | |
| int MITAB_STDCALL | mitab_c_set_collection_multipoint (mitab_feature feature, mitab_feature multipoint, int make_copy) |
| Set or update the multipoint component of a collection. | |
The C wrapper functions contained in mitab_capi.cpp provide a much simpler interface than the OGR-based C++ classes to the MITAB library to read and write .TAB and .MIF files.
To use the C API, simply include "mitab_capi.h" and use the functions defined in mitab_capi.cpp.
See also mitabc_test.cpp which for examples of use of the C API.
See contrib/README_VB.TXT in the MITAB source code distribution for informations on using the MITAB C API from VB, Pascal, or MapBasic.
| int MITAB_STDCALL mitab_c_add_field | ( | mitab_handle | dataset, | |
| const char * | field_name, | |||
| int | field_type, | |||
| int | width, | |||
| int | precision, | |||
| int | indexed, | |||
| int | unique | |||
| ) |
Add a new field to the dataset's schema.
Adding fields MUST be done immediately after creating a new dataset and BEFORE creating the first feature.
| dataset | the mitab_handle of the newly created dataset. | |
| field_name | the name of the new field to create. | |
| field_type | the new field type, one of TABFT_Char (1), TABFT_Integer (2), TABFT_SmallInt (3), TABFT_Decimal (4), TABFT_Float (5), TABFT_Date (6), or TABFT_Logical (7) | |
| width | the width of the new field, applies only to char and decimal types. | |
| precision | the number of digits after the decimal point, applies only to the decimal field type. | |
| indexed | TRUE (1) to create an indexed field (or FALSE (0) for no index) | |
| unique | for indexed fields, set this to TRUE (1) if the field values are guaranteed to be unique, or FALSE (0) otherwise. |
| void MITAB_STDCALL mitab_c_close | ( | mitab_handle | handle | ) |
Close a dataset previously opened using mitab_c_open() or created using mitab_c_create().
| handle | the mitab_handle of the dataset to close. |
| mitab_handle MITAB_STDCALL mitab_c_create | ( | const char * | filename, | |
| const char * | mif_or_tab, | |||
| const char * | mif_projection, | |||
| double | north, | |||
| double | south, | |||
| double | east, | |||
| double | west | |||
| ) |
Create a new .TAB or .MIF dataset.
Note that it is not possible to open a file for update (i.e. read+write) with the current version of the library.
| filename | the complete filename (including extension .TAB or .MIF) of the file to create. | |
| mif_or_tab | one of "mif" to create a .MIF dataset or "tab" to create a .TAB dataset. The default is to create a TAB dataset if this parameter's value is NULL or an empty string. | |
| mif_projection | the projection to use for the dataset, in the same format that is used in the "CoordSys" line of a MIF file header. If this parameter's value is NULL or empty then a LAT/LON coordsys is assumed. See also mitab_c_get_mif_coordsys(). | |
| north | the upper dataset bound. Note that valid bounds are required for a .TAB dataset otherwise data may not be stored properly in the file. MITAB knows the default bounds only for the most common MapInfo coordinate systems, passing north,south,east,west as 0,0,0,0 will instruct MITAB to attempt to use the default bounds for that projection. If no default bounds are found for this projection then your data may not be stored properly in the file unless you provide valid bounds via the north,south,east,west parameters. | |
| south | the lower dataset bound. | |
| east | the right dataset bound. | |
| west | the left dataset bound. |
| mitab_feature MITAB_STDCALL mitab_c_create_feature | ( | mitab_handle | handle, | |
| int | feature_type | |||
| ) |
Create a new mitab_feature object to be written to a dataset created using mitab_c_create().
| handle | the handle of the dataset opened for write access. | |
| feature_type | the type of feature object to create. At this point, only the following types can be created by this C API function: TABFC_NoGeom (0), TABFC_Point (1), TABFC_FontPoint (2), TABFC_CustomPoint (3), TABFC_Text (4), TABFC_Polyline (5), TABFC_Arc (6), TABFC_Region (7), TABFC_Rectangle (8), TABFC_Ellipse (9), TABFC_MultiPoint (10) and TABFC_Collection (11) |
| void MITAB_STDCALL mitab_c_destroy_feature | ( | mitab_feature | feature | ) |
Destroy a mitab_feature object and release all memory associated with it.
| feature | the mitab_feature to destroy. |
| int MITAB_STDCALL mitab_c_get_brush_bgcolor | ( | mitab_feature | feature | ) |
Get an object's brush background color property.
Applies to region, ellipse and rectangle objects.
| feature | the mitab_feature object. |
| int MITAB_STDCALL mitab_c_get_brush_fgcolor | ( | mitab_feature | feature | ) |
Get an object's brush foreground color property.
Applies to region, ellipse and rectangle objects.
| feature | the mitab_feature object. |
| int MITAB_STDCALL mitab_c_get_brush_pattern | ( | mitab_feature | feature | ) |
Get an object's brush pattern property.
Applies to region, ellipse and rectangle objects.
| feature | the mitab_feature object. |
| int MITAB_STDCALL mitab_c_get_brush_transparent | ( | mitab_feature | feature | ) |
Get an object's brush transparency property.
Applies to region, ellipse and rectangle objects.
| feature | the mitab_feature object. |
| mitab_feature MITAB_STDCALL mitab_c_get_collection_multipoint_ref | ( | mitab_feature | feature | ) |
Returns a reference to the multipoint component of a collection.
The returned object is only a reference and remains owned by the collection and will remain valid only during the lifespan of the collection or until the multipoint component is overwritten. The returned feature can be modified but CANNOT be destroyed by the caller.
If the object's geometry is ever modified then a call to mitab_c_set_collection_multipoint() will be required to force updating the internal geometry of the collection.
| feature | the TABFC_Collection feature to read from. |
| mitab_feature MITAB_STDCALL mitab_c_get_collection_polyline_ref | ( | mitab_feature | feature | ) |
Returns a reference to the polyline component of a collection.
The returned object is only a reference and remains owned by the collection and will remain valid only during the lifespan of the collection or until the polyline component is overwritten. The returned feature can be modified but CANNOT be destroyed by the caller.
If the object's geometry is ever modified then a call to mitab_c_set_collection_polyline() will be required to force updating the internal geometry of the collection.
| feature | the TABFC_Collection feature to read from. |
| mitab_feature MITAB_STDCALL mitab_c_get_collection_region_ref | ( | mitab_feature | feature | ) |
Returns a reference to the region component of a collection.
The returned object is only a reference and remains owned by the collection and will remain valid only during the lifespan of the collection or until the region component is overwritten. The returned feature can be modified but CANNOT be destroyed by the caller.
If the object's geometry is ever modified then a call to mitab_c_set_collection_region() will be required to force updating the internal geometry of the collection.
| feature | the TABFC_Collection feature to read from. |
| const char* MITAB_STDCALL mitab_c_get_extended_mif_coordsys | ( | mitab_handle | dataset | ) |
Get the MIF CoordSys string from an opened dataset including the affine transformation parameters if available.
| dataset | the mitab_handle of the source dataset. |
MITAB_AFFINE_PARAMS
| int MITAB_STDCALL mitab_c_get_extended_mif_coordsys_vb | ( | mitab_handle | dataset, | |
| char * | coordsys, | |||
| int | l | |||
| ) |
Get the MIF CoordSys string from an opened dataset including the affine transformation parameters if available.
| dataset | the mitab_handle of the source dataset. | |
| coordsys | a string buffer to return the dataset coordinate system definition in MIF CoordSys format. This value can then be passed to mitab_c_create() to create new datasets with the same coordinate system. Returns empty string if the information could not be read. | |
| l | the maximum length of the coordsys string including terminating null. |
| int MITAB_STDCALL mitab_c_get_feature_count | ( | mitab_handle | handle | ) |
Return the number of features in a dataset.
| handle | the dataset's handle. |
| double MITAB_STDCALL mitab_c_get_field_as_double | ( | mitab_feature | feature, | |
| int | field | |||
| ) |
Fetch an attribute field value in a mitab_feature as a double.
| feature | the mitab_feature object. | |
| field | the index of the field to look at, with 0 being the first field. |
| const char* MITAB_STDCALL mitab_c_get_field_as_string | ( | mitab_feature | feature, | |
| int | field | |||
| ) |
Fetch an attribute field value in a mitab_feature as a string.
The function returns a reference to an internal string buffer that contains the string representation of the attribute field's value (integer and floating point values are converted to string using sprintf()).
| feature | the mitab_feature object. | |
| field | the index of the field to look at, with 0 being the first field. |
| int MITAB_STDCALL mitab_c_get_field_as_string_vb | ( | mitab_feature | feature, | |
| int | field, | |||
| char * | value, | |||
| int | l | |||
| ) |
Fetch an attribute field value in a mitab_feature as a string (VB Version).
The function returns a reference to the string representation of the attribute field's value (integer and floating point values are converted to string using sprintf()).
| feature | the mitab_feature object. | |
| field | the index of the field to look at, with 0 being the first field. | |
| value | string buffer to return the value of the field. | |
| l | the maximum lenght of the value string including terminating null. |
| int MITAB_STDCALL mitab_c_get_field_count | ( | mitab_handle | handle | ) |
Return the number of attribute fields in a dataset's schema.
| handle | the dataset's handle. |
| const char* MITAB_STDCALL mitab_c_get_field_name | ( | mitab_handle | handle, | |
| int | field | |||
| ) |
Return the name of an attribute field in a dataset's schema.
| handle | the dataset's handle. | |
| field | the index of the field to look at, with 0 being the first field. |
| int MITAB_STDCALL mitab_c_get_field_name_vb | ( | mitab_handle | handle, | |
| int | field, | |||
| char * | name, | |||
| int | l | |||
| ) |
Return the name of an attribute field in a dataset's schema (VB version).
| handle | the dataset's handle. | |
| field | the index of the field to look at, with 0 being the first field. | |
| name | string buffer to return the field name. | |
| l | the maximum lenght of the name string including terminating null. |
| int MITAB_STDCALL mitab_c_get_field_precision | ( | mitab_handle | handle, | |
| int | field | |||
| ) |
Return the precision of an attribute field in a dataset's schema.
| handle | the dataset's handle. | |
| field | the index of the field to look at, with 0 being the first field. |
| int MITAB_STDCALL mitab_c_get_field_type | ( | mitab_handle | handle, | |
| int | field | |||
| ) |
Return the type of an attribute field in a dataset's schema.
| handle | the dataset's handle. | |
| field | the index of the field to look at, with 0 being the first field. |
| int MITAB_STDCALL mitab_c_get_field_width | ( | mitab_handle | handle, | |
| int | field | |||
| ) |
Return the width of an attribute field in a dataset's schema.
| handle | the dataset's handle. | |
| field | the index of the field to look at, with 0 being the first field. |
| const char* MITAB_STDCALL mitab_c_get_font | ( | mitab_feature | feature | ) |
Get the font name from a TABFC_Text or TABFC_FontPoint object, or the symbol name from a TABFC_CustomPoint.
| feature | the mitab_feature object. |
| int MITAB_STDCALL mitab_c_get_font_vb | ( | mitab_feature | feature, | |
| char * | font, | |||
| int | l | |||
| ) |
Get the font name from a TABFC_Text or TABFC_FontPoint object, or the symbol name from a TABFC_CustomPoint.
(VB Version)
| feature | the mitab_feature object. | |
| font | string buffer to return the text font name. | |
| l | the maximum lentgh of the text string including terminating null. |
| const char* MITAB_STDCALL mitab_c_get_mif_coordsys | ( | mitab_handle | dataset | ) |
Get the MIF CoordSys string from an opened dataset.
| dataset | the mitab_handle of the source dataset. |
| int MITAB_STDCALL mitab_c_get_mif_coordsys_vb | ( | mitab_handle | dataset, | |
| char * | coordsys, | |||
| int | l | |||
| ) |
Get the MIF CoordSys string from an opened dataset (VB Version).
| dataset | the mitab_handle of the source dataset. | |
| coordsys | a string buffer to return the dataset coordinate system definition in MIF CoordSys format. This value can then be passed to mitab_c_create() to create new datasets with the same coordinate system. Returns empty string if the information could not be read. | |
| l | the maximum length of the coordsys string including terminating null. |
| int MITAB_STDCALL mitab_c_get_parts | ( | mitab_feature | feature | ) |
Return the number of parts (rings or polyline segments) in an object.
| feature | the mitab_feature object. |
| int MITAB_STDCALL mitab_c_get_pen_color | ( | mitab_feature | feature | ) |
Get an object's pen color property.
Applies only to polyline, region, rectangle, arc and ellipse objects.
| feature | the mitab_feature object. |
| int MITAB_STDCALL mitab_c_get_pen_pattern | ( | mitab_feature | feature | ) |
Get an object's pen pattern property.
Applies only to polyline, region, rectangle, arc and ellipse objects.
| feature | the mitab_feature object. |
| int MITAB_STDCALL mitab_c_get_pen_width | ( | mitab_feature | feature | ) |
Get an object's pen width property.
Applies only to polyline, region, rectangle, arc and ellipse objects.
| feature | the mitab_feature object. |
| mitab_projinfo MITAB_STDCALL mitab_c_get_projinfo | ( | mitab_handle | dataset | ) |
Get the projinfo handle from an opened dataset.
| dataset | the mitab_handle of the source dataset. |
| double MITAB_STDCALL mitab_c_get_symbol_angle | ( | mitab_feature | feature | ) |
Get an font point object's angle property.
Applies only to point objects of type TABFC_FontPoint
| feature | the mitab_feature object. |
| int MITAB_STDCALL mitab_c_get_symbol_color | ( | mitab_feature | feature | ) |
Get an object's symbol color property.
Applies only to point and multipoint objects.
| feature | the mitab_feature object. |
| int MITAB_STDCALL mitab_c_get_symbol_no | ( | mitab_feature | feature | ) |
Get an object's symbol number property.
Applies only to point and multipoint objects.
| feature | the mitab_feature object. |
| int MITAB_STDCALL mitab_c_get_symbol_size | ( | mitab_feature | feature | ) |
Get an object's symbol size property.
Applies only to point and multipoint objects.
| feature | the mitab_feature object. |
| const char* MITAB_STDCALL mitab_c_get_text | ( | mitab_feature | feature | ) |
Get the text string on a TABFC_Text object.
| feature | the mitab_feature object. |
| double MITAB_STDCALL mitab_c_get_text_angle | ( | mitab_feature | feature | ) |
Fetch a TABFC_Text object's angle property.
| feature | the mitab_feature object. |
| int MITAB_STDCALL mitab_c_get_text_bgcolor | ( | mitab_feature | feature | ) |
Fetch a TABFC_Text object's background color property.
| feature | the mitab_feature object. |
| int MITAB_STDCALL mitab_c_get_text_fgcolor | ( | mitab_feature | feature | ) |
Fetch a TABFC_Text object's foreground color property.
| feature | the mitab_feature object. |
| double MITAB_STDCALL mitab_c_get_text_height | ( | mitab_feature | feature | ) |
Fetch a TABFC_Text object's MBR height property.
| feature | the mitab_feature object. |
| int MITAB_STDCALL mitab_c_get_text_justification | ( | mitab_feature | feature | ) |
Fetch a TABFC_Text object's justification property.
| feature | the mitab_feature object. |
| int MITAB_STDCALL mitab_c_get_text_linetype | ( | mitab_feature | feature | ) |
Fetch a TABFC_Text object's linetype property.
| feature | the mitab_feature object. |
| int MITAB_STDCALL mitab_c_get_text_spacing | ( | mitab_feature | feature | ) |
Fetch a TABFC_Text object's spacing property.
| feature | the mitab_feature object. |
| int MITAB_STDCALL mitab_c_get_text_vb | ( | mitab_feature | feature, | |
| char * | text, | |||
| int | l | |||
| ) |
Get the text string on a TABFC_Text object (VB Version).
| feature | the mitab_feature object. | |
| text | string buffer to return the text string in the object. | |
| l | the maximum length of the text string including terminating null. |
| double MITAB_STDCALL mitab_c_get_text_width | ( | mitab_feature | feature | ) |
Fetch a TABFC_Text object's MBR width property.
| feature | the mitab_feature object. |
| int MITAB_STDCALL mitab_c_get_type | ( | mitab_feature | feature | ) |
Return a mitab_feature's object type.
| feature | the mitab_feature object. |
| int MITAB_STDCALL mitab_c_get_vertex_count | ( | mitab_feature | feature, | |
| int | part | |||
| ) |
Return the number of points in a part of a mitab_feature object.
| feature | the mitab_feature object. | |
| part | the part number we are interested in. Use 0 for objects which cannot have multiple parts. |
| double MITAB_STDCALL mitab_c_get_vertex_x | ( | mitab_feature | feature, | |
| int | part, | |||
| int | vertex | |||
| ) |
Return the X coordinate of a point in a part of a mitab_feature object.
| feature | the mitab_feature object. | |
| part | the part number we are interested in. Use 0 for objects which cannot have multiple parts. | |
| vertex | the point number, with 0 being the first point. |
| double MITAB_STDCALL mitab_c_get_vertex_y | ( | mitab_feature | feature, | |
| int | part, | |||
| int | vertex | |||
| ) |
Return the Y coordinate of a point in a part of a mitab_feature object.
| feature | the mitab_feature object. | |
| part | the part number we are interested in. Use 0 for objects which cannot have multiple parts. | |
| vertex | the point number, with 0 being the first point. |
| const char* MITAB_STDCALL mitab_c_getlasterrormsg | ( | ) |
Get the last error message.
Fetches the last error message posted with CPLError(), that hasn't been cleared by CPLErrorReset(). The returned pointer is to an internal string that should not be altered or freed.
| int MITAB_STDCALL mitab_c_getlasterrormsg_vb | ( | char * | errormsg, | |
| int | l | |||
| ) |
Get the last error message (VB Version).
Fetches the last error message posted with CPLError(), that hasn't been cleared by CPLErrorReset(). The returned pointer is to an internal string that should not be altered or freed.
| errormsg | string buffer to return the last error message (will return an empty string if there is no posted error message). | |
| l | the maximum length of the errormessage string including terminating null. |
| int MITAB_STDCALL mitab_c_getlasterrorno | ( | ) |
Fetch the last error number.
This is the error number, not the error class.
| int MITAB_STDCALL mitab_c_getlibversion | ( | ) |
Returns the version of the library.
| int MITAB_STDCALL mitab_c_is_field_indexed | ( | mitab_handle | handle, | |
| int | field | |||
| ) |
Test whether specified field in a dataset's schema is indexed or not.
| handle | the dataset's handle. | |
| field | the index of the field to look at, with 0 being the first field. |
| int MITAB_STDCALL mitab_c_is_field_unique | ( | mitab_handle | handle, | |
| int | field | |||
| ) |
For indexed fields only, test whether the specified indexed field in a dataset's schema has the unique flag set.
| handle | the dataset's handle. | |
| field | the index of the field to look at, with 0 being the first field. |
| int MITAB_DLL MITAB_STDCALL mitab_c_is_interior_ring | ( | mitab_feature | feature, | |
| int | requestedringindex | |||
| ) |
Return a false if te ring is the first of a polygon.
| feature | the mitab_feature object. | |
| requestedringindex | the requested ring index |
| int MITAB_STDCALL mitab_c_load_coordsys_table | ( | const char * | filename | ) |
Load a Coordsys bounds lookup table from an external file.
The entries from that table will be looked up in priority BEFORE the default bounds predefined for each coordsys inside the MITAB library. This allows users to override the default bounds for existing projections, and to define bounds for new projections not already supported by MITAB.
The format of the file is a simple text file with one CoordSys string per line. The CoordSys lines should follow the MIF specs, and MUST include the optional Bounds definition at the end of the line.
e.g. CoordSys Earth Projection 8, 24, "m", -63, 0, 0.9996, 500000, 0 Bounds \ (-7746230.6469039, -9998287.383889269) (8746230.6469039, 9998287.383889269)
| filename | the filename of the table to load. Path is relative to the current working directory or can |