# This file was auto-generated by Fern from our API Definition.

import typing

import pydantic
import typing_extensions
from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
from ..core.serialization import FieldMetadata


class GeoEllipse(UniversalBaseModel):
    """
    An ellipse shaped geo-entity.
     For a circle, the major and minor axis would be the same values.
     This shape is NOT Geo-JSON compatible.
    """

    semi_major_axis_m: typing_extensions.Annotated[typing.Optional[float], FieldMetadata(alias="semiMajorAxisM")] = (
        pydantic.Field(default=None)
    )
    """
    Defines the distance from the center point of the ellipse to the furthest distance on the perimeter in meters.
    """

    semi_minor_axis_m: typing_extensions.Annotated[typing.Optional[float], FieldMetadata(alias="semiMinorAxisM")] = (
        pydantic.Field(default=None)
    )
    """
    Defines the distance from the center point of the ellipse to the shortest distance on the perimeter in meters.
    """

    orientation_d: typing_extensions.Annotated[typing.Optional[float], FieldMetadata(alias="orientationD")] = (
        pydantic.Field(default=None)
    )
    """
    The orientation of the semi-major relative to true north in degrees from clockwise: 0-180 due to symmetry across the semi-minor axis.
    """

    height_m: typing_extensions.Annotated[typing.Optional[float], FieldMetadata(alias="heightM")] = pydantic.Field(
        default=None
    )
    """
    Optional height above entity position to extrude in meters. A non-zero value creates an elliptic cylinder
    """

    if IS_PYDANTIC_V2:
        model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True)  # type: ignore # Pydantic v2
    else:

        class Config:
            frozen = True
            smart_union = True
            extra = pydantic.Extra.allow
