initial structure implemented

docs -> _docs
This commit is contained in:
Oleksandr Bezdieniezhnykh
2025-12-01 14:20:56 +02:00
parent 9134c5db06
commit abc26d5c20
360 changed files with 3881 additions and 101 deletions
+21
View File
@@ -0,0 +1,21 @@
from pydantic import BaseModel, field_validator
class GPSPoint(BaseModel):
lat: float
lon: float
@field_validator("lat")
@classmethod
def validate_lat(cls, v: float) -> float:
if not -90 <= v <= 90:
raise ValueError("Latitude must be between -90 and 90")
return v
@field_validator("lon")
@classmethod
def validate_lon(cls, v: float) -> float:
if not -180 <= v <= 180:
raise ValueError("Longitude must be between -180 and 180")
return v