From e8e7a76076ce416dce909082afaf62f6a523f352 Mon Sep 17 00:00:00 2001 From: Fred Boniface Date: Wed, 26 Jun 2024 13:07:44 +0100 Subject: [PATCH] Prep work for addition of location data for TIPLOCS --- bplan/bplan.go | 7 +++++++ bplan/fetch.go | 3 +++ bplan/types.go | 13 +++++++++++++ coordinates/coordinates.go | 3 +++ 4 files changed, 26 insertions(+) create mode 100644 bplan/bplan.go create mode 100644 bplan/fetch.go create mode 100644 bplan/types.go create mode 100644 coordinates/coordinates.go diff --git a/bplan/bplan.go b/bplan/bplan.go new file mode 100644 index 0000000..2a0c6e9 --- /dev/null +++ b/bplan/bplan.go @@ -0,0 +1,7 @@ +package bplan + +// Returns: a slice of objects containing a TIPLOC, Latitude and Longitude +func GetTiplocLocations() []TiplocLatLong {} + +// Returns: a slice of objects containing a TIPLOC, Easting and Northing +func GetTiplocLocationsOS() []TiplocOS {} diff --git a/bplan/fetch.go b/bplan/fetch.go new file mode 100644 index 0000000..6aead03 --- /dev/null +++ b/bplan/fetch.go @@ -0,0 +1,3 @@ +package bplan + +// Fetch BPLAN data - nothing more, nothing less diff --git a/bplan/types.go b/bplan/types.go new file mode 100644 index 0000000..9fe9f6d --- /dev/null +++ b/bplan/types.go @@ -0,0 +1,13 @@ +package bplan + +type TiplocLatLong struct { + Tiploc string + Latitude float64 + Longitude float64 +} + +type TiplocOS struct { + Tiploc string + Easting int64 + Northing int64 +} diff --git a/coordinates/coordinates.go b/coordinates/coordinates.go new file mode 100644 index 0000000..d54c7d1 --- /dev/null +++ b/coordinates/coordinates.go @@ -0,0 +1,3 @@ +package coordinates + +// Converts, fairly roughly between OS and GPS coordinates