Shared Samples

Try out source code samples stored in Bitbucket repositories.
Showing results for 
Search instead for 
Do you mean 

Job vectorRead

by Technical Evangelist on ‎09-08-2015 11:02 AM - edited on ‎03-29-2016 11:34 AM by Anonymous (793 Views)

Example Type






This example shows how to read vector features such as arcs, polygons, tics and points from a vector layer.




vectorRead.c (C source code)

vectorRead.eml (EML script)

vectorRead.dsp (Visual C++ Project)(Windows Only)





The vectorRead example is intended to illustrate the following procedures:

  • how to open a vector layer,
  • how to read the descriptive information about that layer,
  • how to read the features (arc, polygons, points, tics) in the layer, and
  • How to read some attribute table data.

The results are written to a text file for later viewing.

This example demonstrates how to use the four major functions that retrieve information from the vector layer:

  1. readVectorLayer
  2. readVectorFeatures
  3. read AttributeTable
  4. describeVector Layer




Command Line Options


vectorread -in <inputfile> -out <outputfile> [-m <0|1>]



 This is the input vector that will be described.



 This is the output text file describing the vector layer.



 Specifies whether or not to meter the process. 0 is no and 1 (default) is yes.







This example produces an output text file that contains information about arcs, polygons, points and tics within the vector layer.




This program will print information about every feature and every attribute in the coverage, so please be aware that a large coverage may result in a large, unusable text file!



Source Code: