across.tools.core.schemas.polygon

Classes

Polygon

Class to represent a spherical polygon

Module Contents

class Polygon(/, **data)[source]

Bases: across.tools.core.schemas.base.BaseSchema

Class to represent a spherical polygon

coordinates: list[across.tools.core.schemas.coordinate.Coordinate][source]
model_post_init(__context)[source]

Pydantic post-init hook

Post-Init validations.

1.) a polygon must contain a list of coordinates 1.) a polygon’s first and final coordinates must be the same (wrapping) 2.) a polygon has more than 3 unique coordinates

__repr__()[source]

Overrides the print statement

__eq__(other)[source]

Overrides the coordinate equals