Manages multiple roads and their respective public transport systems. More...
#include <Transportation.h>
Public Member Functions | |
| void | addRoad (Road road) |
| Adds a road to the road system. | |
| void | upgrade () |
| Upgrades the road system. | |
| int | getUtilization () |
| Gets the overall utilization of the road system. | |
| vector< Road > & | getRoads () |
| Gets the list of roads in the system. | |
Manages multiple roads and their respective public transport systems.
This class tracks the number of roads and their utilization.
| void RoadSystem::addRoad | ( | Road | road | ) |
Adds a road to the road system.
| road | The Road object to add. |
| vector< Road > & RoadSystem::getRoads | ( | ) |
Gets the list of roads in the system.
| int RoadSystem::getUtilization | ( | ) |
Gets the overall utilization of the road system.