gtiosclub / Nomad

Fall 2024 Project
0 stars 2 forks source link

Create fetchRoute() method within FirebaseViewModel #277

Closed VigneshSK17 closed 3 days ago

VigneshSK17 commented 3 weeks ago

@DattaKansal Added the changes to MapManager and NomadRoute for storing and fetching routes in Firebase at the branch linked to this issue.

Here the design I had in mind for the storage of the Route in Firebase:

Trip -> TripId -> Route -> RouteId -> { coords: [String] expectedTravelTime: TimeInterval (Encodable) direction: Turf.LocationDistance (Double) }

Storing in Firebase: storeRoute(route: NomadRoute)

Fetching from Firebase: fetchRoute(routeId: UUID, mapManager: MapManager)