Retrieve polygon centroid


Purpose
The centroid of a polygon is the center of mass of an irregular polygon. This sample takes in a shapefile with a polygon feature class and reports back the centroids.

How to use

See How to use ArcGIS samples for help on running the sample.

  1. Run the RetrievePolygonCentroid application.
  2. Examine the output.

If you installed the samples feature, you will find the files associated with this sample in <Your Developer Kit install location>\DeveloperKit10.4\Java\Samples\ArcObjects.

geometry/RetrievePolygonCentroid.java Main class.




Development licensing Deployment licensing
Engine Developer Kit Engine