How cs250-fall-2026-team-5/roadwatch works
RoadWatch is a Kotlin Multiplatform road-hazard reporting app for Android, iOS, and desktop. Users can search maps, view location-oriented UI, and submit hazard reports; the shared app validates and stores reports through a repository abstraction. Device location has a shared service and platform-specific providers, while map rendering also has platform-specific implementations. The desktop entry point selects SQLite persistence; other targets default to in-memory storage. Edges reflect excerpts, SOURCE INDEX references, or README statements; unsampled implementations and their wiring are not inferred.
Main entry points: App.kt Compose app UI · LocationCoordinates.kt Coordinates · main.kt Desktop entry · Geolocator.kt Location provider API
Components 23
App clients
- Android entry
androidApp/src/main/kotlin/edu/sdsu/cs250/team5/road_watch/MainActivity.kt - iOS entry
iosApp/iosApp/ContentView.swift - Desktop entry
desktopApp/src/main/kotlin/edu/sdsu/cs250/team5/road_watch/main.kt
Shared experience
- Compose app UI
shared/src/commonMain/kotlin/edu/sdsu/cs250/team5/road_watch/App.kt
Location and maps
- Location view state
shared/src/commonMain/kotlin/edu/sdsu/cs250/team5/road_watch/MainViewController.kt - Location service
shared/src/commonMain/kotlin/edu/sdsu/cs250/team5/road_watch/LocationService.kt - Coordinates
shared/src/commonMain/kotlin/edu/sdsu/cs250/team5/road_watch/LocationCoordinates.kt - Location provider API
shared/src/commonMain/kotlin/edu/sdsu/cs250/team5/road_watch/Geolocator.kt - Android locator
shared/src/androidMain/kotlin/edu/sdsu/cs250/team5/road_watch/Geolocator.android.kt - iOS locator
shared/src/iosMain/kotlin/edu/sdsu/cs250/team5/road_watch/Geolocator.ios.kt - JVM locator
shared/src/jvmMain/kotlin/edu/sdsu/cs250/team5/road_watch/Geolocator.jvm.kt - Shared map UI
shared/src/commonMain/kotlin/edu/sdsu/cs250/team5/road_watch/map.kt - Android map
shared/src/androidMain/kotlin/edu/sdsu/cs250/team5/road_watch/map.android.kt - iOS map
shared/src/iosMain/kotlin/edu/sdsu/cs250/team5/road_watch/map.ios.kt - JVM map
shared/src/jvmMain/kotlin/edu/sdsu/cs250/team5/road_watch/map.jvm.kt
Hazard reports
- Hazard model
shared/src/commonMain/kotlin/edu/sdsu/cs250/team5/road_watch/Hazard.kt - Report submission
shared/src/commonMain/kotlin/edu/sdsu/cs250/team5/road_watch/ReportSubmissionController.kt - Report validation
shared/src/commonMain/kotlin/edu/sdsu/cs250/team5/road_watch/ReportValidator.kt
Persistence
- Repository interface
shared/src/commonMain/kotlin/edu/sdsu/cs250/team5/road_watch/HazardRepository.kt - Repository selection
shared/src/commonMain/kotlin/edu/sdsu/cs250/team5/road_watch/HazardRepositoryProvider.kt - SQLite repository
shared/src/jvmMain/kotlin/edu/sdsu/cs250/team5/road_watch/storage/SqliteHazardRepository.kt - SQLite database
Other components
- App user
Connections 26
- App user → Android entry: uses
- App user → iOS entry: uses
- App user → Desktop entry: uses
- Android entry → Compose app UI: starts
androidApp/src/main/kotlin/edu/sdsu/cs250/team5/road_watch/MainActivity.kt - iOS entry → Compose app UI: embeds
iosApp/iosApp/ContentView.swift - Desktop entry → Compose app UI: starts
desktopApp/src/main/kotlin/edu/sdsu/cs250/team5/road_watch/main.kt - Desktop entry → Repository selection: sets repository
desktopApp/src/main/kotlin/edu/sdsu/cs250/team5/road_watch/main.kt - Desktop entry → SQLite repository: initializes
desktopApp/src/main/kotlin/edu/sdsu/cs250/team5/road_watch/main.kt - Compose app UI → Repository selection: uses
shared/src/commonMain/kotlin/edu/sdsu/cs250/team5/road_watch/App.kt - Compose app UI → Hazard model: uses
shared/src/commonMain/kotlin/edu/sdsu/cs250/team5/road_watch/App.kt - Report submission → Repository interface: submits to
shared/src/commonMain/kotlin/edu/sdsu/cs250/team5/road_watch/ReportSubmissionController.kt - Repository interface → Report validation: validates with
shared/src/commonMain/kotlin/edu/sdsu/cs250/team5/road_watch/HazardRepository.kt - Repository selection → Repository interface: selects
shared/src/commonMain/kotlin/edu/sdsu/cs250/team5/road_watch/HazardRepositoryProvider.kt - SQLite repository → Repository interface: implements
shared/src/jvmMain/kotlin/edu/sdsu/cs250/team5/road_watch/storage/SqliteHazardRepository.kt - SQLite repository → SQLite database: reads and writes
shared/src/jvmMain/kotlin/edu/sdsu/cs250/team5/road_watch/storage/SqliteHazardRepository.kt - Location view state → Location service: fetches location
shared/src/commonMain/kotlin/edu/sdsu/cs250/team5/road_watch/MainViewController.kt - Location service → Location provider API: tracks location
shared/src/commonMain/kotlin/edu/sdsu/cs250/team5/road_watch/LocationService.kt - Location service → Coordinates: returns
shared/src/commonMain/kotlin/edu/sdsu/cs250/team5/road_watch/LocationService.kt - Location provider API → Android locator: implemented by
shared/src/androidMain/kotlin/edu/sdsu/cs250/team5/road_watch/Geolocator.android.kt - Location provider API → iOS locator: implemented by
shared/src/iosMain/kotlin/edu/sdsu/cs250/team5/road_watch/Geolocator.ios.kt - Location provider API → JVM locator: implemented by
shared/src/jvmMain/kotlin/edu/sdsu/cs250/team5/road_watch/Geolocator.jvm.kt - Shared map UI → Location view state: uses
shared/src/commonMain/kotlin/edu/sdsu/cs250/team5/road_watch/map.kt - Shared map UI → Coordinates: uses
shared/src/commonMain/kotlin/edu/sdsu/cs250/team5/road_watch/map.kt - Android map → Coordinates: uses
shared/src/androidMain/kotlin/edu/sdsu/cs250/team5/road_watch/map.android.kt - iOS map → Coordinates: uses
shared/src/iosMain/kotlin/edu/sdsu/cs250/team5/road_watch/map.ios.kt - JVM map → Coordinates: uses
shared/src/jvmMain/kotlin/edu/sdsu/cs250/team5/road_watch/map.jvm.kt