Parts Collection in MapObjects

Geometrically, you might think that a polyline (Line class) or a polygon (Polygon class) is nothing more than an ordered collection of vertex points. However, in MO, the Line and Polygon classes support multiple parts. So in the object model, the collection of these parts is stored in the Line/Polygon’s Parts property. Each “part” is a collection of points–a Points collection object.

Imagine for a moment a donut polygon which has an outer ring of vertex points and an inner ring of vertex points. In this case, the Polygon object has a Parts property, and that Parts property contains two parts, that is, two Points collection objects. The first Points collection is an ordered collection of vertex points which make up the outer ring, and the second Points collection is an ordered collection of vertex points which make up the inner ring.

And, by the way, outer rings are always oriented clockwise, and inner rings must always be oriented counter-clockwise. 

Advertisements

One Response to “Parts Collection in MapObjects”

  1. Rajani Kumar Rebba Says:

    Nice

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s


%d bloggers like this: