How hasnainarefin/project-2-1 works
This is a terminal-based Khulna ambulance dispatch system. The main workflow is account/menu interaction, patient and pickup handling, normal or emergency request prioritization, ambulance and hospital selection, route display/animation, and trip logging. Administration, fleet and hospital management, location search, map/zone analytics, and trip/action history are separate capabilities. Edges reflect calls and references visible in the provided excerpts or SOURCE INDEX; some menu flows and subsystems are only partially sampled, so their internal links are omitted.
Main entry points: main.cpp Startup and saves · fleet_hospitals.cpp Ambulance and hospitals · city_graph.cpp Khulna road graph · dispatch.cpp Trip dispatch
Components 18
Application entry
- Startup and saves
main.cpp - User and admin menus
app_menu.cpp - Shared records and console
common.cpp
Dispatch operations
- Trip dispatch
dispatch.cpp - Ambulance and hospitals
fleet_hospitals.cpp
City and routing
- Map and animation
map_view.cpp - Khulna road graph
city_graph.cpp - Graph and zone traversal
traversal.cpp - Location sorting and search
sort_search.cpp
Accounts and records
- Accounts and patients
hash_tables.cpp - Trips and action log
trip_history.cpp - Fleet save file
khulna_fleet.dat - Hospital save file
khulna_hospitals.dat - Patient save file
khulna_patients.dat - Account save file
khulna_accounts.dat - Trip save file
khulna_trips.dat
Request handling
- Request queues
requests.cpp
Other components
- Operator
Connections 28
- Operator → User and admin menus: uses
app_menu.cpp - Startup and saves → User and admin menus: runs
main.cpp - Startup and saves → Khulna road graph: initializes
main.cpp - Startup and saves → Graph and zone traversal: initializes zones
main.cpp - User and admin menus → Accounts and patients: looks up accounts
app_menu.cpp - User and admin menus → Request queues: uses queues
app_menu.cpp - User and admin menus → Trip dispatch: starts dispatch
app_menu.cpp - Trip dispatch → Ambulance and hospitals: selects and updates
dispatch.cpp - Trip dispatch → Khulna road graph: routes with
dispatch.cpp - Trip dispatch → Map and animation: animates route
dispatch.cpp - Trip dispatch → Trips and action log: logs trip
dispatch.cpp - Ambulance and hospitals → Khulna road graph: ranks by distance
fleet_hospitals.cpp - Ambulance and hospitals → Location sorting and search: sorts rankings
fleet_hospitals.cpp - Ambulance and hospitals → Graph and zone traversal: checks reachability
fleet_hospitals.cpp - Map and animation → Khulna road graph: reads roads and nodes
map_view.cpp - Graph and zone traversal → Khulna road graph: reads neighbors
traversal.cpp - Location sorting and search → Khulna road graph: searches locations
sort_search.cpp - Trips and action log → Location sorting and search: sorts trip report
trip_history.cpp - Startup and saves → Ambulance and hospitals: loads and saves fleet
main.cpp - Startup and saves → Hospital save file: loads and saves
main.cpp - Startup and saves → Patient save file: loads and saves
main.cpp - Startup and saves → Account save file: loads and saves
main.cpp - Startup and saves → Trip save file: loads and saves
main.cpp - Ambulance and hospitals → Fleet save file: reads and writes
fleet_hospitals.cpp - Ambulance and hospitals → Hospital save file: reads and writes
fleet_hospitals.cpp - Accounts and patients → Shared records and console: uses records
hash_tables.cpp - Request queues → Shared records and console: uses helpers
requests.cpp - Trips and action log → Shared records and console: uses helpers
trip_history.cpp