Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
36 changes: 36 additions & 0 deletions design/01_System_Context.puml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
@startuml OSMTracker-System-Context
!pragma layout smetana
!theme plain

' C4-PlantUML Context diagram
!include https://raw.githubusercontent.com/plantuml-stdlib/C4-PlantUML/master/C4_Context.puml

LAYOUT_TOP_DOWN()

title OSMTracker for Android – System Context
caption Context diagram showing OSMTracker for Android in its environment

Person(user, "OSM Mapper / Outdoor User", "Records GPS tracks and adds POIs while surveying")

System(system, "OSMTracker for Android", "Mobile app to record GPX tracks, capture photos/voice notes, and mark POIs")

System_Ext(openStreetMap, "OpenStreetMap", "Uploads GPX traces, notes and provides map tiles for on-device maps")
System_Ext(androidOS, "Android Operating System Services (GPS/Network/Media)", "Provides location updates and captures photos and voice notes via Android Camera/Media APIs")
System_Ext(githubApi, "GitHub API", "Uploads GPX/trace files to a repository; lists repos; creates PRs")

Rel(user, system, "Records tracks, creates POIs, takes photos/notes")

Rel(system, androidOS, "Receives location updates and captures media", "Android APIs")

Rel(system, openStreetMap, "Uploads GPX traces/notes and fetches data", "HTTPS/REST")
Rel(system, githubApi, "Lists repos, uploads files, opens PRs", "HTTPS/REST with token")

UpdateElementStyle(user, $fontColor="black", $bgColor="#CFE8FF", $borderColor="#3A8DFF")
UpdateElementStyle(system, $fontColor="black", $bgColor="#C7F0D8", $borderColor="#1B8C3E")
UpdateElementStyle(openStreetMap, $bgColor="#FFE4C4")
UpdateElementStyle(githubApi, $bgColor="#FFE4C4")

SHOW_LEGEND()

footer Generated with C4-PlantUML.
@enduml
1 change: 1 addition & 0 deletions design/01_System_Context.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
48 changes: 48 additions & 0 deletions design/02_Containers_Osmtracker.puml
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
@startuml OSMTracker-Containers
!pragma layout smetana
!theme plain

' C4-PlantUML Container diagram
!include https://raw.githubusercontent.com/plantuml-stdlib/C4-PlantUML/master/C4_Container.puml

LAYOUT_TOP_DOWN()

title OSMTracker for Android – Containers
caption Containers inside OSMTracker for Android, and how they interact with external systems

Person(user, "OSM Mapper / Outdoor User", "Records GPS tracks and adds POIs while surveying")

System_Boundary(system, "OSMTracker for Android") {
Container(mobileApp, "Android Mobile App", "Java", "UI and background logic to record tracks, manage POIs, capture media, and upload/export")
ContainerDb(localDb, "Local Database", "SQLite", "Tracks, waypoints/POIs, settings, and related metadata")
Container(fileStore, "Local File Storage", "Android filesystem", "GPX exports, photos, audio notes and temporary ZIPs")
}

System_Ext(openStreetMap, "OpenStreetMap", "Uploads GPX traces; provides map tiles (HTTPS)")
System_Ext(androidOS, "Android Operating System Services (GPS/Network/Media)", "Location updates; Camera/Microphone/Media APIs")
System_Ext(githubApi, "GitHub API", "Upload trace files to a repository; list repos; open PRs")

' People -> App
Rel(user, mobileApp, "Uses to start/stop tracking, add POIs, take photos/voice notes")

' Internal container relationships
Rel(mobileApp, localDb, "Reads/Writes track and waypoint metadata")
Rel(mobileApp, fileStore, "Reads/Writes GPX, photos, audio, ZIPs")

' External relationships
Rel(mobileApp, androidOS, "Receives location updates; triggers media capture", "Android APIs")
Rel(mobileApp, openStreetMap, "Uploads GPX traces and notes; fetches map tiles", "REST/HTTPS")
Rel(mobileApp, githubApi, "Lists repos, uploads files, opens PRs", "HTTPS")

UpdateElementStyle(user, $fontColor="black", $bgColor="#CFE8FF", $borderColor="#3A8DFF")
UpdateElementStyle(system, $fontColor="black", $bgColor="#C7F0D8", $borderColor="#1B8C3E")
UpdateElementStyle(openStreetMap, $bgColor="#FFE4C4")
UpdateElementStyle(androidOS, $bgColor="#FFE4C4")
UpdateElementStyle(githubApi, $bgColor="#FFE4C4")
UpdateElementStyle(localDb, $bgColor="#FFF9C4")
UpdateElementStyle(fileStore, $bgColor="#FFF9C4")

SHOW_LEGEND()

footer Generated with C4-PlantUML.
@enduml
1 change: 1 addition & 0 deletions design/02_Containers_Osmtracker.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
52 changes: 52 additions & 0 deletions design/03_Components_NotesUpload.puml
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
@startuml OSMTracker-Components-NotesUpload
!pragma layout smetana
!theme plain

' C4-PlantUML Components diagram
' Focused on the "Upload OpenStreetMap Notes" flow
!include https://raw.githubusercontent.com/plantuml-stdlib/C4-PlantUML/master/C4_Component.puml

LAYOUT_TOP_DOWN()

title OSMTracker for Android – Components (Notes Upload)
caption Zoom-in of the Mobile App showing components involved in uploading Notes to OpenStreetMap

Person(user, "OSM Mapper / Outdoor User", "Creates text notes and uploads them to OSM")

Container_Boundary(app, "Android Mobile App") {
Component(waypointList, "WaypointList", "Activity", "Lists waypoints/notes; entry point to OSM Notes upload")
Component(osmNotesUpload, "OpenStreetMapNotesUpload", "Activity", "Collects note text and location; prepares upload")
Component(uploadNotesTask, "UploadToOpenStreetMapNotesTask", "AsyncTask", "Creates OSM Notes via OsmConnection + NotesApi")

Component(dataHelper, "DataHelper", "Helper", "Gateway to ContentProvider (SQLite) and per-track directories")
Component(contentProvider, "TrackContentProvider", "ContentProvider", "CRUD for tracks/points/waypoints; app-wide data access")
Component(dbHelper, "DatabaseHelper", "SQLiteOpenHelper", "Creates/upgrades schema; indices and columns for entities")
}

' External system for the flow
System_Ext(osmNotesApi, "OpenStreetMap API β€” Notes", "Uploads the notes to OpenStreetMap")

' User interaction with the UI
Rel(user, waypointList, "Chooses notes to upload / opens upload screen")

' Internal collaborations for the Notes flow
Rel(waypointList, osmNotesUpload, "Starts upload with selected waypoint(s)")
Rel(osmNotesUpload, dataHelper, "Reads waypoint(s) and metadata (location, text)")
Rel(osmNotesUpload, uploadNotesTask, "Initiates upload of notes")
Rel(dataHelper, contentProvider, "Uses ContentResolver to query waypoints/track data")
Rel(contentProvider, dbHelper, "Uses SQLite database")

' External connection
Rel(uploadNotesTask, osmNotesApi, "Creates notes (HTTPS)")

' Styling consistent with other C4 views
UpdateElementStyle(user, $fontColor="black", $bgColor="#CFE8FF", $borderColor="#3A8DFF")
UpdateElementStyle(app, $fontColor="black", $bgColor="#C7F0D8", $borderColor="#1B8C3E")
UpdateElementStyle(osmNotesApi, $bgColor="#FFE4C4")
UpdateElementStyle(contentProvider, $bgColor="#FFF9C4")
UpdateElementStyle(dbHelper, $bgColor="#FFF9C4")

SHOW_LEGEND()

footer Generated with C4-PlantUML.
@enduml
1 change: 1 addition & 0 deletions design/03_Components_NotesUpload.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.