Table of Contents

Class GeoPolygon

Namespace
H3.NET.Native
Assembly
H3.NET.Native.dll

A polygon defined by an exterior ring and zero or more interior holes, with all vertices expressed in degrees.

public sealed class GeoPolygon
Inheritance
GeoPolygon
Inherited Members

Remarks

Rings are open: the first and last vertices should not be repeated; H3 implicitly closes each loop. Winding order does not affect H3 region operations.

Constructors

GeoPolygon(IReadOnlyList<LatLng>, IReadOnlyList<IReadOnlyList<LatLng>>?)

Initializes a new instance of the GeoPolygon class.

public GeoPolygon(IReadOnlyList<LatLng> exterior, IReadOnlyList<IReadOnlyList<LatLng>>? holes = null)

Parameters

exterior IReadOnlyList<LatLng>

The exterior ring vertices, in degrees.

holes IReadOnlyList<IReadOnlyList<LatLng>>

The interior hole rings, each a list of vertices in degrees; may be null or empty.

Exceptions

ArgumentNullException

exterior is null.

Properties

Exterior

Gets the exterior ring vertices, in degrees.

public IReadOnlyList<LatLng> Exterior { get; }

Property Value

IReadOnlyList<LatLng>

Holes

Gets the interior hole rings, each a list of vertices in degrees.

public IReadOnlyList<IReadOnlyList<LatLng>> Holes { get; }

Property Value

IReadOnlyList<IReadOnlyList<LatLng>>