Show / Hide Table of Contents

    Class Polygon

    A GeoJSON polygon.

    Inheritance
    System.Object
    Geometry
    Polygon
    Inherited Members
    Geometry.Type
    System.Object.Equals(System.Object)
    System.Object.Equals(System.Object, System.Object)
    System.Object.GetHashCode()
    System.Object.GetType()
    System.Object.MemberwiseClone()
    System.Object.ReferenceEquals(System.Object, System.Object)
    System.Object.ToString()
    Namespace: Elements.GeoJSON
    Assembly: Hypar.Elements.dll
    Syntax
    public class Polygon : Geometry

    Constructors

    Polygon(Position[][])

    Construct a Polygon.

    Declaration
    public Polygon(Position[][] coordinates)
    Parameters
    Type Name Description
    Position[][] coordinates

    Properties

    Coordinates

    The coordinates of the geometry.

    Declaration
    [JsonProperty("coordinates")]
    public Position[][] Coordinates { get; }
    Property Value
    Type Description
    Position[][]

    Methods

    ToPolygons(Position)

    Convert the coordinate array to a collection of polygons. The last position of the polygon is dropped.

    Declaration
    public Polygon[] ToPolygons(Position relativeToOrigin)
    Parameters
    Type Name Description
    Position relativeToOrigin
    Returns
    Type Description
    Polygon[]